Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
stascher
Partner - Creator II
Partner - Creator II

Calculating % change from baseline in line chart

StudentProgram DayWeight
Bob A1205
Bob A10200
Bob A15198
John A1225
John A20220

 

Given the above table, I want to generate a line chart that displays, for each Student by Program Day, the % change in the Student's weight from their first recorded Weight value; ie (current weight - first weight) / first weight.  Note that I say first Weight instead of weight on Day 1 because the first weight doesn't have to coincide with Day 1 but it will always be recorded on the lowest Program Day value for that student. 

How do I reference the first weight value in my % change expression? 

Thanks, Steve

Labels (4)
1 Reply
marcus_sommer

Maybe you could use something like this:

num(firstsortedvalue(Weight, -[Program Day]) / firstsortedvalue(Weight, [Program Day]) - 1, '0.0%')
   or maybe
num(firstsortedvalue(Weight, -[Program Day]) / only(Weight) - 1, '0.0%')

- Marcus