Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Is it possible to dynamically change the color of the line in a line chart?
For example, can I have the first x values be red, and the rest be black?
One other option:
Go to Expression Tab.
Expand the expression.
Select the Background color
Add a condition if(rowno()<10 ,RGB(0,236,0),RGB(255,100,255))
Note: This won't work if the graph is sorted according to y value.
Yes, go to the Colors tab of your chart properties, click on one of the colors and put in a calculated color. You have a separate color for the first 18 lines, so you would have to define all the ones you wanted as red to be red and the rest black. You could use a variable to make the number of red lines be dynamic,
I've tried the Calculated color, but I'm not sure what to put in for the formula to give me, for example, the first 5 values of the chart.
I assume I should be using an If statement here.
One other option:
Go to Expression Tab.
Expand the expression.
Select the Background color
Add a condition if(rowno()<10 ,RGB(0,236,0),RGB(255,100,255))
Note: This won't work if the graph is sorted according to y value.
Thank you, this was exactly what I was looking for.