about the axis scale?

hello, I am dealing with electrophysiology data from HEKA device. Unforturnately, the data has to be processed in Igor. I am not familar with this software. So, there are stupid questions.

I want to plot Voltage-Time curves. My exported data is ploted by Igor in the unit of V and s, which is not what I want (I want it show mV and ms).

Could you tell me, if there are modules that can automatically change the axis unit scale? or any other easy ways to conduct this task are welcome. I found that if the axis range is reduced to a certain point, the axis unit can automatically change to mV or ms. But the range is not what I want.

And, what is the function of "trial exponential" in the page of Axis label? I didnot see it can change something in the plot between the two alternative choices.
Thank you all.
Hi

I hope that, after you get some experience using Igor, you won't find it "unfortunate" that you have to use it :)

The "trial exponential" radio button options you asked about are there to let you see how the axis label will look when the order of magnitude of the quantity displayed changes.

What you probably want to do is to set the exponent prescale for both of your axes. You do this in the Modify Axis dialog (double click on an axis to bring it up), in the "Ticks and Grids" tab. If your wave data is in units of V and s, then you want to set Exponent Prescale to 3 for both axes. You'll also need to make sure that the range of data displayed on both axes makes sense with respect to the prescale value you just set. If you're x axis ranges from 0 s to 100 s and you've set exponent prescale to 3, Igor will still use s as the unit (instead of ms) because it would have to add too many zeros to the tick mark labels and the graph wouldn't look good.

Here is some example code you can run yourself that should explain what I mean. You can copy this code into Igor's command line and execute it by pressing enter and you should get a graph on which the data is displayed as mv vs ms.

make jack=p
SetScale/P x 0,1,"s", jack     // Set the wave's x units
SetScale d 0,0,"V", jack      // Set the wave's data units
display jack      // At this point, data is displayed as V vs. s
ModifyGraph prescaleExp=3
SetAxis left 0,1
SetAxis bottom 0,1


By the way, if you're new to Igor, I really suggest that you take the time to go through the Guided Tour. It might take you an hour or two, depending on how fast you go through it, but I think you'll find that it is well worth your time. You can bring up the guided tour by clicking on Igor's Help -> Getting Started menu item. Alternately, I'm in the process of creating a series of video tutorials that go through the Guided Tour. I haven't finished them yet, but there are quite a few that are done. You can access them at http://www.wavemetrics.com/products/igorpro/videotutorials.htm. Finally, feel free to ask questions here on IgorExchange, the Igor Pro mailing list, and/or directly to WaveMetrics support. You can get more information about these resources on the IgorExchange Support page.
Dear aclight,

Thank you so much! So, my stupid question has been solved by changing exponential prescale value, which is exactly what I want. Excellent!

I know igor is very powerful in processing data and graph. I will take more time on the manual to better exert this software's power!

Thank you again, best wishes!
Sorry, my another two questions about this topic:

1. How to make a plot with axises in a form like the attached graph? Is there sepcial modules for this purpose?
2. How to switch the X axis with unit "s" in a time course graph into "min" or "hour"?

Thank you very much!
pic.JPG
That little axis is what we call a "calibrator".

In Igor's Graph menu, choose Packages->Append Calibrator.

Enter the values for the x and y length, choose an orientation, and click Add Calibrator to Layer.

Software Engineer, WaveMetrics, Inc.
myye wrote:
1. How to make a plot with axises in a form like the attached graph? Is there sepcial modules for this purpose?


Not really a special mode. You first need to create the graph with all of the traces on it. You can do that like you usually would, either on the command line or using the New Graph or Append Traces To Graph dialog boxes. You'll want to make sure to append all of the traces to the same axes, which is what is done by default. The next thing you want to do is to hide the axes. You can do this by selecting the graph you want to act on and then execute the following command on Igor's command line:
ModifyGraph nticks=0,noLabel=2,axThick=0

What this command does is set the thickness of the axes to 0, removes axis labels, and sets there to be 0 ticks. These settings can also be changed in the Modify Axis dialog.

At this point you'll have what you want, but you won't have the scale bars. There is a procedure file that ships with Igor that makes it pretty easy to add scale bars. To use it, select your graph and choose the Graph -> Packages -> Append Calibrator menu item. The panel this creates is pretty self explanatory. This package uses Igor's built in drawing tools to add the scale bars. If you need to tweak them in a way that's not supported by the panel, you can do that manually. You might want to first read up on Igor's drawing tools, however. For more information execute the following command at Igor's command line:
DisplayHelpTopic "Drawing"


Thank you so much, dear friends!
raising questions here is quite efficient to go through the problems in using Igor. So, I have know how to plot a graph by Igor that has a seperated scale bar.

How about the switching among the unit of second, minute, and hours on the X axis, which could be encountered in plotting time course graph by common users like me? Thank you for your excellent answers!
myye wrote:
2. How to switch the X axis with unit "s" in a time course graph into "min" or "hour"?


If your present X axis is in seconds, you can get an axis labelled in hh:mm:ss by following these steps:

1) Double-click your X axis to bring up the Modify Axis dialog (be sure the cursor shows a double-headed arrow before double-clicking- that shows it is truly pointing at the axis)
2) On the Axis tab, choose Date/Time in the Mode box.
3) On the Ticks and Grids tab, in the Date/Time Tick Labels box, choose Elapsed from the Time Format menu.

It is likely that the axis label now reads "dat". This reflects special units set on the wave to request the date/time axis. You can use the Axis Label tab to set the label text to something better.

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
Thank you for your quick reply!

My point is that in the time course graph, for instance, the maximun value of the x axis may be 600s, which is not good in a presentation. I would like it show 10 min. Or 3600s is shown as 1hr. I mean how to change the unit of X Axis among sec, min or hour as needed, not mean the form of date(xxxx-xx-xx) or time format like XX:XX. I am sorry that I didnot describe clear for you.
Thank you very much for your helps. This could be my last curious question on graph ploting by igor software.
Best wishes!
myye wrote:
... for instance, the maximun value of the x axis may be 600s, which is not good in a presentation. I would like it show 10 min. Or 3600s is shown as 1hr. ...


I am not clear that you are using a voltage wave versus a time wave or you are using a scaled voltage wave.

Presuming the former, one way to change the "time increment" is to change the VALUES of the time wave. Consider this example of converting a wave of seconds (ts) to minutes (tm) or hours (th) waves ...

duplicate ts tm, th  // duplicate the seconds wave into minute and hour waves
tm/=60  // dividing by 60 converts seconds to minutes
th/=3600  // dividing by 3600 converts seconds to hours


You could also just convert the original wave ...

twave/=60 // converts time wave from seconds to minutes


Alternatively, if your voltage wave is scaled in time as seconds, you should change the wave scaling. This works best when the last data point corresponds to an exact time in minutes or hours. Otherwise, the irrational conversion fractions from seconds to minutes (1/60) or seconds to hours (1/3600) create problems. For a voltage wave that is exactly 120 s long (the END data point is measured at at time of 120 s), the conversion from seconds to minutes is ...

SetScale/I x 0,2,"min", voltage


myye wrote:
This could be my last curious question on graph ploting by igor software.


Well, as you use Igor Pro more, you will likely have further questions. Answering them is the role of this forum and the email list.

--
J. J. Weimer
Chemistry / Chemical & Materials Engineering, UAH
myye wrote:
My point is that in the time course graph, for instance, the maximun value of the x axis may be 600s, which is not good in a presentation. I would like it show 10 min. Or 3600s is shown as 1hr. I mean how to change the unit of X Axis among sec, min or hour as needed, not mean the form of date(xxxx-xx-xx) or time format like XX:XX. I am sorry that I didnot describe clear for you.


jjweimer's answer is correct- you can convert a wave of seconds to a wave of minutes simply by dividing by 60. But the result will be a graph with minutes and fractions of minutes. Most people don't think easily about what 6.6 minutes means. If I were you, I would use the elapsed time display I described previously. Naturally, you are free to do whatever you like :)
myye wrote:
Thank you very much for your helps. This could be my last curious question on graph ploting by igor software.

I hope not- that would mean that you had stopped using Igor!

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
hi, friends, Thank you very much for your excellent answers. I have got the solutions in changing graph scales as needed by Jjweimer's method.
By the way, I mean that question could be my last one on this topic. I will undoubltedly continue to use igor and enjoy using it as being more familar with this powerful software. Thank you all!
johnweeks wrote:
.... you can convert a wave of seconds to a wave of minutes simply by dividing by 60. But the result will be a graph with minutes and fractions of minutes. Most people don't think easily about what 6.6 minutes means.


I had the impression that showing a 3600 s tick as a tick with a 60 min or a 1 h value while still displaying data points over the entire range of times in between the ticks was important to myye, perhaps for example to illustrate trend(s) over minute or hour intervals (rather than on second by second intervals).

In other words, even though folks may not think easily about 6.6 minutes (versus that in seconds) as a specific data point, they may still be fine to see axis ticks at whole minute or hour increments with data points in between.

Another thought that occurred to me is for myye to use the Transform Axis package to create an appended axis noted in minute or hour increments to supplement the seconds axis. More information is available under the File:Example Experiments:Feature Demos 2:Transform Axis Demo menu option.

--
J. J. Weimer
Chemistry / Chemical & Materials Engineering, UAH
It occurred to me that there are two more methods for making unusual ticking for graph axes. One is "computed manual ticks" in which you specify the tick increment yourself. You could set the tick increment to 60 and you would get a tick labelled 60, 120, etc. Still in seconds, but the labels fall every minute.

Another, harder, method is to use "user tick waves". If you do that, you can have any tick labels you want, including non-numeric. For instance, if your data are in seconds, but you want a tick every minute, and you want the labels to be 1, 2, etc. (that is, labels in minutes) you can make these waves:

Make/T tickLabels={"0","1","2","3","4"}
Make tickPositions={0,60,120,180,240}


Then select those waves in the Modify Axis dialog, Auto/Man Ticks tab. On that tab in the dialog, select User Ticks from Waves. Then select the waves made above from the menus in the User Tick Waves area.

You might need to have more rows in the waves if your data extens beyond 300 seconds. You can make these waves in a more automated way:

Make/N=10/T/O tickLabels
Make/N=10 tickPositions
tickLabels = num2str(p)
tickPositions = p*60


These commands will make labels suitable for up to 10 minutes of data.

You can use a variation on this scheme for hourly ticks. There are options using this method to add minor ticks, unlabelled ticks, etc. Read more:

DisplayHelpTopic "User Ticks from Waves"

John Weeks
WaveMetrics, Inc.
support@wavemetrics.com