LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Can I use strings to label the X-axis of my waveform graph?

I want to plot a graph, no_of_units_in_job against job_number and I want to label the X-axis with the Job Numbers, how do I do this, is it possible?

I have included a the graph that I made but I labeled the x-axis using the label too, what am trying to find out is that is it possible to programatically label the x-axis because I will be getting the info to plot from the database?
0 Kudos
Message 1 of 12
(5,569 Views)
Hi,

you should use the graph properties to show/hide and set x scale name.

I modified your example to show how.

Good luck,

Alberto
Message 2 of 12
(5,570 Views)
Thanks for the quick response Alberto but I have got at the moment LabVIEW 6.01 and the example you submited is in 6.02. so I can't really look at your vi.
Is there a way around that?

D!
0 Kudos
Message 3 of 12
(5,570 Views)
Sorry I meant o say I have 6.02 and the vi you gave me is in 6.1.
0 Kudos
Message 4 of 12
(5,570 Views)
there it is,

Alberto
0 Kudos
Message 5 of 12
(5,570 Views)
Thanks a lot for the help on labelling the X-axis. Now what am trying to do is to have a graph that displays lets say, country against population and I want the country to be display on the x-axis as a string for obviously reasons, can i programatically do that or does LabVIEW jus allow numbers and not strings on the x-axis? Here is what I sort of what to do...
Edge!
0 Kudos
Message 6 of 12
(5,570 Views)
Hi again,

I had a similar need time ago; what I did was to add a picture below my graph and display the strings in it.
I modified your vi to explain simply the principle.
If you have different numbers of points you should progammatically change the insertion points of text in the picture.

Hope it was helpful,

Alberto
Message 7 of 12
(5,570 Views)
Oh Alberto you are the man, that example was exactly what I needed, you even made it possible for me to actaully control the labels on the x-axis using string controls and the picture can be transparent to allow the labels to show just the way I want them. Thanks a lot, really appreciate it.
Edge!
0 Kudos
Message 8 of 12
(5,570 Views)

Hi there! I had a similiar issue here. is there really no way to use, say, an array of string as an axis in a graph? Because the thing is,  i want to make a graph that have 2 x-axis, one is the numerical one as primary axis and one with the string label for each numerical value. the max- and min value for the primary axis need to be changed programmatically, and the corresponding label move along with the primary axis. Any ideas?

 

 

0 Kudos
Message 9 of 12
(5,135 Views)

Hi opiq,

 

Do you mean that as you change the scale, the string should just keep its positioning above the values that you are programmatically changing?

0 Kudos
Message 10 of 12
(5,111 Views)