02-02-2016 05:51 AM
Solved! Go to Solution.
02-02-2016 06:13 AM
A single plot has a single color. Period.
So if you want to have different colors in "a single plot", you have to fake it by using multiple plots. XY Graph helps as it simplifies positioning of plots next to each other.
Norbert
02-02-2016 07:28 AM
02-02-2016 08:31 AM
You should take a look into the context help of the XY Graph to learn how to bundle multiple plots.
The next to look into is how to make X-arrays for all these fake plots to get an appearance of "one single plot".
Norbert
02-02-2016 09:09 AM
02-02-2016 09:39 AM
The second plot you add will be an array of the same length as your data (and the same X-array), with all of the y-values set to NaN (this prevents it from appearing on the graph). When you know which point you want to "change color", copy it's value into the same location in the second plot's cluster. Set the color of plot2 to whatever you want. This can be done for any point on the graph (lets say you wanted to color all points above a certain threshold, just repeat above steps for each point of interest).
02-02-2016 10:19 AM
@pjr1121 wrote:The second plot you add will be an array of the same length as your data (and the same X-array), with all of the y-values set to NaN (this prevents it from appearing on the graph).
This will work but it is not necessary to have an array of the same lenght, you can have a single point array. Select plot type that doesn't include line and point type that you can see on the graph.
Ben64
02-02-2016 11:55 AM
also I think on other method I think it is more easy to work with
just a bit work on coordinates conversion's
02-04-2016 01:22 PM
Hi all,
I am so grateful to you guys, It's really work. Thanks again
Regards