Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Line Chart with total column

Dear All,

How to display total value in line chart with two dimensions. In this example just treat as Month and Department as dimensions, 3 Department sum values along with toal line should be displayed in chart.

Please let me know in case you need any more information.

Regards,

Ravi,

1 Reply
swuehl
MVP
MVP

Ravi,

you could create a new dimension, maybe called DepartmentChart, that has new value Total linked to all Departments, together with each Department linked to itself:

INPUT:

CrossTable(Month, Data)

LOAD Department,

     Jan,

     Feb,

     Mar,

     Apr,

     May,

     Jun,

     Jul,

     Aug,

     Sep,

     Oct,

     Nov,

     Dec

FROM

[.\Sample Line Chart.xlsx]

(ooxml, embedded labels, table is Sheet1, filters(

Remove(Row, Pos(Top, 6)),

Remove(Row, Pos(Top, 5))

));

DepartmentChart:

LOAD 'Total' as DepartmentChart autogenerate 1;

Join (DepartmentChart) Load Distinct Department resident INPUT;

Concatenate LOAD Department, Department as DepartmentChart resident INPUT;

Then use a line chart with dimensions Month and DepartmentChart (you can change the label for that, of course) and with an expression =sum(Data)

That should be enough, please see attached.

Stefan