From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Probability plot - question

Hi,

I'm trying to generate probability plot for 2 sets of data, but I don't like output that I got.

This is graph that is generated in Minitab, and that's how I would like to look like

Capture2.JPG

 

And this is what I get in LV

Capture.JPG

 

As it can be seen, problem is in Y axis, Minitab has this nice not sure what is a name but like double logarithmic scale, expanded scale on bottom and top of X-axis.

On VI XY scatterplot I can only get typical Logarithmic scale but this does not look

even close to visualisation that I would like to get.

0 Kudos
Message 1 of 11
(4,299 Views)

LabVIEW does not allow custom axis mappings (this would help, for example).

 

Of course you could do it all in a picture control and some custom code. 😄

0 Kudos
Message 2 of 11
(4,267 Views)

At the very least you can set you Y-axis as Log.  Right click on a value in teh y-axis and select "Mapping/Logarthmic", see image below.

log_y.png

 

 

 

 

To get that exact scale you might need to look outside the standard LabVIEW plots.  Try looking at the Advance Plotting Toolkit - http://advancedplotting.github.io/

0 Kudos
Message 3 of 11
(4,263 Views)

The scale has very little to do with logarithmic, Note that in the upper half things are reversed and the spacings get wider again.

0 Kudos
Message 4 of 11
(4,259 Views)

Minitab is a statistics software, so maybe the Y axis is a bell curve on its side, with a custom scale to straighten out the curve?

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
Message 5 of 11
(4,243 Views)

Yep, that's why I called it double logarithmic, because I don't know correct name. But Y scale upper half is inverted of bottom half.

0 Kudos
Message 6 of 11
(4,228 Views)

@altenbach wrote:

The scale has very little to do with logarithmic, Note that in the upper half things are reversed and the spacings get wider again.


altenbach - True and obvious now that I look at this on a PC (I shouldn't squint at pictures on my phone!)   And I hope your suggestion for scales gets implemented!

 

I don't see this feature in the APT either.   But you can do it with matplotlib (upon which APT is built).  This explains how the scales are generated - http://matplotlib.org/mpl-probscale/tutorial/closer_look_at_viz.html

 

 

 

0 Kudos
Message 7 of 11
(4,192 Views)

That's pretty interesting stuff, actually - and I'm not even a statistician!  I can't think of a way to do this - but it might be a good idea for the Idea Exchange.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 8 of 11
(4,188 Views)

@billko wrote:

Minitab is a statistics software, so maybe the Y axis is a bell curve on its side, with a custom scale to straighten out the curve?


Thanks for advise, at the end I do it in that way, and now result is very similar to Minitab graph, example with 4 data sets at the end.

In previous tests I used Gauss White noisy to generate distribution for Y graph (as i seen on several examples in internet), and there were 2 problems.

First one is that this is normal distribution which does not fit for me since I want this double logarithmic thing on Y scale or whatever name is.

Second is that this generator creates distribution pretty far away from ideal normal distribution, it generates some pseudo random pattern which is maybe good to simulate some realistic situation but when I check histogram of of that generated samples, distribution is pretty deformed from typical ideal Gauss shape, with some spikes, which at the end resulted with additional weird deformation on my X-Y plot.

So at the end for Y graph I used template which I generated with help of Minitab/Excel after some time of playing I produce template of 1000 samples which I stored in LV  in a form of one array (Y graph template).

Since that I have for X scale input up to 4 data sets (Track 1 / 2 / 3 / 4), and each of this data sets have not specified sample size, it can be for instance in range 100 - 1000 per track, for each X data set I generate Y scale pair of same sample size.

While I generate Y pair data set, I use mentioned Y graph template. 

For instance, template has fixed 1000 samples, and my specific X data set (Track) has 300 samples, I generate 300  samples using "interpolate 1D array" and excavate data from template to generate my desired 300 samples.

Only I had to turn off Y-scale scale ticks since it is displayed as linear and only confuse.

Pictures of final result below

Capture3.JPGCapture4.JPG

 

Message 9 of 11
(4,169 Views)

Don't forget to mark your OWN post as the solution, since it was you who figured out how to satisfactorily display the data!  🙂

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 10 of 11
(4,161 Views)