Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Compare last to first and last to previous

I have a series of periodic measurements on patients that consist of 6 criteria per measurement. I need to find the difference between measurements comparing the most recent to the first, or the most recent to the previous. I need to compare them criterion by criterion, checking which have improved or decreased and then counting and if the number of improvements outnumber the decreased, then the patient is said to have improved. Each patient can have a different number of measurements.

I am relatively new to Qlikview do not know if the best way to approach this is through the script, or if it can be done in a chart. I have tried both and had little success. Any suggestions? I have attached sample data.

1 Solution

Accepted Solutions
Not applicable
Author

I got it. Thanks. It is a little discouraging I didn’t see it myself, but your solution opened my eyes to using the script better. Thanks very much.

View solution in original post

5 Replies
Gysbert_Wassenaar

See attached example for one solution. I've assumed that the measurements M1 is the first, M2 the second etc. If that's incorrect you'll need to explain how to derive the correct order.


talk is cheap, supply exceeds demand
Not applicable
Author

That looks good for comparing to the previous measurement (it is so simple once you see it), how would you do a comparison with the first measurement? Thanks.

Not applicable
Author

I got it. Thanks. It is a little discouraging I didn’t see it myself, but your solution opened my eyes to using the script better. Thanks very much.

Anonymous
Not applicable
Author

Hi,

  Can you please fiend the attachment of application.

Regards

Not applicable
Author

Thanks, both approaches worked. Thanks for your help.