Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
BlazkoG
Contributor III
Contributor III

cumulative sum line chart with calculated dimension, problem with series

 Hi, I have a problem with cumulative sum line chart, the problem is I think I need to aggr by dimension, but im usin calculated one, and puting it in the formula gives rubbish chart result.
So I'm playin with covid19 data. Columns of interest: date, cases, deaths, country.
Ive calculated on visualisation purposes dimension like:
day_0: =Aggr(nodistinct min({<cases=-{'0'}>}date),countriesAndTerritories)

//marks day with first case confirmed

day_count:=if(
date-Aggr(NODISTINCT min({<cases=-{'0'}>}date),countriesAndTerritories)<0,
0,
date-Aggr(NODISTINCT min({<cases=-{'0'}>}date),countriesAndTerritories)

//counts following days from day_0

Then I have a cumulative sum of Cases cinfirmed:

RangeSum(Above(total sum(cases),1,RowNo(total)))

 

I want to show it as a line chart, with day_count and country as  dimensions. When i filter one country its, ok, problem is when i want to show more countries as a series. Then instead of something like that (example from power bi):
Adnotacja 2020-06-16 195150.jpg

 

I get this:

Adnotacja 2020-06-16 195tgtrr150.jpg

thx for any help 🙂

edit: link to source table:
https://opendata.ecdc.europa.eu/covid19/casedistribution/csv 

edit2:

dont know why, but when i convert this chart to pivot table, it works correctly:

Adnot717.jpg

Labels (2)
0 Replies