LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

set y axis values from array

hi

    i am ploting a intensity plot where  y axis is having particular frequency  values. ex ..[ 1 3 6 7 20 30 .....] how to set this values as y axis values....

------------------------------------------------------------------------------------------------------------------
Indrajit

| indrajitbarve@gmail.com | indar_indar2005@yahoo.co.in .
0 Kudos
Message 1 of 6
(3,871 Views)

Indrajit,

 

I have found a way for you to accomplish this in LabView.

 

You can use property nodes to programmatically change the values of your axes of the intensity plot. 

 

To do this:

 

Open your block diagram and right-click on the "Intensity Chart" or "Intensity Graph" icon. 

Go to:

Create-> Property Node -> Y Scale ->Marker Values. 

Once the property node is created, then you can expand the node and add the additional following properties.

Y Scale -> Maximum

Y Scale -> Minimum

 

You may have to right-click on the property node and click "Change All to Write."

 

From here, you can put an array of numbers into the graph to generate the markers where you would like them.  Note that this does not change the scale of the graph, only the place that the markers are place.

 

I have included a small example diagram and resulting front end for your reference.

 

YScale-MarkerVals-Block.jpg YScale-MarkerVals-Front.jpg

 

 

I hope that this helps you out.

 

0 Kudos
Message 2 of 6
(3,738 Views)

I don't think there is enough information to solve this.


indrajit wrote:

    i am ploting a intensity plot where  y axis is having particular frequency  values. ex ..[ 1 3 6 7 20 30 .....] how to set this values as y axis values....


The data for an intensity graph is an array and the x and y axis values are linearly tied to the array indices (via x0 and dx), so if the values quoted above correspond to the frequency of each row you are out of luck. The solution above would just selectively display a few y-values. It does not take into account the nonlinear remapping between array index and actual value.

 

What you could do is create new rows with many more points by interpolation to generate data that is equally spaced in frequency.

0 Kudos
Message 3 of 6
(3,731 Views)

Hello, I know it's been a couple of years but I thought I'd just ask because this thread is relevant to what I need to do.

 

I am using an intensity graph to display an array of values which may be 256x256, 512x512 or 1024x1024 by user specification. I've tried using the method outlined above to set the max and min of each axis to one of these strange numbers, but I can't locate the appropriate attributes on the property node. Screenshot attached.

 

I'd be grateful if anyone can help me out.

---------------------------------------------------------------------
LabVIEW 2013, Windows 7

He who asks the question is a fool for five minutes; he who does not ask the question remains a fool forever.
0 Kudos
Message 4 of 6
(3,480 Views)

Just in case anyone sees this, I have since worked around this problem.

---------------------------------------------------------------------
LabVIEW 2013, Windows 7

He who asks the question is a fool for five minutes; he who does not ask the question remains a fool forever.
0 Kudos
Message 5 of 6
(3,462 Views)

It is not a problem and you don't need a workaround. You just need to properly descent into sub-branches of the properties. 🙂

0 Kudos
Message 6 of 6
(3,457 Views)