Forum Discussion
owlet0214
6 years agoHelper I
Difference from previous cell
Hello, I want to make a custom column that calculates the difference from the previous cell. The testedPositive is not the increasing number of people on that day, but the cumulative total up to...
- 6 years agoUnless it is prefecture columns throwing things off I would think:
diff = [testedPositive] - maxx(filter('prefectures4',[prefectureNameE]=earlier([prefectureNameE]) && [Last date] <earlier([Last date])),[testedPositive])
owlet0214
6 years agoHelper I
Thanks a lot !
I haven't gotten the expected number yet, but I think it's getting closer to the correct answer.
I will try a little more.
I use below.
Last date = maxx(filter('prefectures4',[prefectureNameE]=earlier([prefectureNameE]) && [YYYYMMDD2] <earlier([YYYYMMDD2])),[YYYYMMDD2])
diff = [testedPositive] - maxx(filter('prefectures4',[prefectureNameE]=earlier([prefectureNameE]) && [YYYYMMDD2] <earlier([Last date])),[testedPositive])
Greg_Deckler
6 years agoCommunity Champion
Unless it is prefecture columns throwing things off I would think:
diff = [testedPositive] - maxx(filter('prefectures4',[prefectureNameE]=earlier([prefectureNameE]) && [Last date] <earlier([Last date])),[testedPositive])
diff = [testedPositive] - maxx(filter('prefectures4',[prefectureNameE]=earlier([prefectureNameE]) && [Last date] <earlier([Last date])),[testedPositive])