Grid Trend - Ref value

Find and share HowTos to various installations / configurations!
8 posts • Page 1 of 1
AMRPatricio
Posts:61
Joined: Mon Dec 12, 2016 4:43 pm

Grid Trend - Ref value

Post by AMRPatricio »

Hi All,
I plan to implement something and I would like to have your opinion: for my trend I have different Ref values/lines that I would like to see represented on the grid. I can see that it is possible to define a ref value for the grid and also the spacing below/above which is going to set the number of grid lines that are shown above/below the reference value .
But on my specific case the grid lines that I want to represent do not follow a constant distance from the ref value. For example assuming the ref value is 500, I want to represent the following grid lines:450(90%refvalue), 300(60%refvalue), 150(30%refvalue)

Any ideas?

Thanks in advance.

Antonio

fmulder
Posts:330
Joined: Wed Feb 03, 2010 9:46 am

Re: Grid Trend - Ref value

Post by fmulder »

You could add 3 extra lines to your trend. You do not connect these lines to a datapoint but instead fill them via scripting.

Or,
* Make some extra lines
* Add code to the 'scroll' event of the trend widget
* In the scroll event-> Use scripting to add fake values to your lines

Hope this helps

share the fun
Frenk Mulder

AMRPatricio
Posts:61
Joined: Mon Dec 12, 2016 4:43 pm

Re: Grid Trend - Ref value

Post by AMRPatricio »

Hi Frenk,
thanks for reply.

"You could add 3 extra lines to your trend. You do not connect these lines to a datapoint but instead fill them via scripting.", I guess you meant "curves" not lines?

I want to represent grid lines, which represent thresholds from my curve.

Thanks,
Antonio

fmulder
Posts:330
Joined: Wed Feb 03, 2010 9:46 am

Re: Grid Trend - Ref value

Post by fmulder »

So... ?

Just make 3 fake lines and call them 'grid1', 'grid2' and 'grid3'.
Instead of connecting them to a datapoint YOU add the points to the lines by scripting.

mkoller
Posts:741
Joined: Fri Sep 17, 2010 9:03 am

Re: Grid Trend - Ref value

Post by mkoller »

Use "curveMarking" to define extra reference lines (as many as you like) per curve.

AMRPatricio
Posts:61
Joined: Mon Dec 12, 2016 4:43 pm

Re: Grid Trend - Ref value

Post by AMRPatricio »

Hi Martin,
thank you for your idea but "curveMarking" only allow me to create one single line per curve(or a range), not multiple single lines.

Thanks
Antonio

mkoller
Posts:741
Joined: Fri Sep 17, 2010 9:03 am

Re: Grid Trend - Ref value

Post by mkoller »

You are wrong.
Try the following example code:

Code: Select all

  this.curveMarking("#1_2", 1, 100, 100, "red", "[dashed,oneColor,JoinMiter,CapButt,0]");
  this.curveMarking("#1_2", 2, 120, 120, "red", "[dashed,oneColor,JoinMiter,CapButt,0]");
  this.curveMarking("#1_2", 3, 160, 160, "red", "[dashed,oneColor,JoinMiter,CapButt,0]");

AMRPatricio
Posts:61
Joined: Mon Dec 12, 2016 4:43 pm

Re: Grid Trend - Ref value

Post by AMRPatricio »

Thanks for your help Martin .

8 posts • Page 1 of 1