7.9 Accumulation for continuous occurrence of a certain condition
There is a statistical table for daily sales:
We want to add a column to the right to calculate the cumulative days of consecutive rising (calculate in cell C1):
A | |
---|---|
1 | =0 |
2 | return E(‘A1:B32’).new(if(Sales>Sales[-1], A1=A1+1,A1=0):RiseDayCount) |
A2: Take A1 as a temporary value. A1 plus 1 when the sales volume rises, and assign A1 to 0 when the sales volume falls.
https://c.scudata.com/article/1651916536524
https://c.scudata.com/article/1654825822056
https://c.scudata.com/article/1654923726358
SPL Official Website 👉 https://www.esproc.com
SPL Feedback and Help 👉 https://www.reddit.com/r/esProc_Desktop/
SPL Learning Material 👉 https://c.esproc.com
Discord 👉 https://discord.gg/2bkGwqTj
Youtube 👉 https://www.youtube.com/@esProcDesktop
Linkedin Group 👉 https://www.linkedin.com/groups/14419406/