Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

StartDate EndDate percentage calculation

Hello all,

learning Qlik for about 3 weeks ))) and

I need your help with simple task I have.

Data set:

name       Time- date   price

a1                Jan 1          20

a2                Jan 2          22

a3                Jan 3          20

a4                Jan 4          24

b1                Jan 1          10

b2                Jan 2          15

b3                Jan 3          30

b4                Jan 4          33

Task: calculate % between two dates I choose with vStartDate and vEndDate variables and visualize it as Block Chart.

I feel that it could be really simple, but have not got the logic yet (((. 

Labels (1)
1 Reply
Not applicable
Author

I've worked it out using the expression

=Num (1-( FirstSortedValue([Close], [Time-Date], 1)  / FirstSortedValue([Close], -1*[Time-Date], 1) ))*100

not sure if this is a correct one, however it works for now, but not as Block Chart (won't show negative values with positive), thus I use Bar Chart temporarily.