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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
aaarox
Contributor
Contributor

Expression in coloring the points into a line graph

Hi community,

i need help in creating an expression to use for coloring groups of values with different colors  in a line graph.

In this graph, I represent a variabile that should be between two limits.

I would like to evidence (by coloring in red the points) all those points outside the limits for AT LEAST 5 CONSECUTIVE TIMES.

In this way I can avoid to highlights all those points that can be considered as outliers.

I'm trying to use a combination of RangeSum and Above but I don't find the correct formula.

I hope someone could help me.

Thanks,

Andrea

Labels (2)
1 Reply
Aasir
Creator III
Creator III

Use below.
Replace YourVariable, LowerLimit, and UpperLimit with the actual field names and limit values from your data.


if(
RangeSum(
Above(
if(
YourVariable < LowerLimit or YourVariable > UpperLimit,
1,
0
),
0, RowNo()
)
) >= 5
or
RangeSum(
Above(
if(
YourVariable < LowerLimit or YourVariable > UpperLimit,
1,
0
),
0, RowNo()
)
) = 0,
Red(),
Black()
)