Forum Discussion

cmiller's avatar
cmiller
Data Storage
01-20-2025
Solved

How to add a benchmark/trend line based on dynamic conditions to a chart?

Hello,  I'd like to add trend lines to a line chart (like this) but based on the data existing in the chart. For example the benchmark line would be 5% higher than CVR1 and the Target line would be...
  • HamzaJ's avatar
    01-21-2025

    Hey cmiller ,

    I dont know if the following is what you are looking for, but it can perhaps point you in the right direction. I do not know a lot of javascript so I tend not to meddle with it. 

    In your case what you could do is;

    • Create a new measure in your chart
    • Give it the formula CVR1 * 1.05
    • Press OK, select the three dots and change the chart type of that measure to line
    • Rename the measure to Benchmark

    Repeat for Target line. Both lines will now be based on the value of CVR1 for that week and not be a static line.

    Hamza