I am confused about the notations (x) and (num) in Volume V "Reference" of IgorMan.pdf. For example, I don't see any difference between the properties of the variables of the built-in operations digamma(x) and gamma(num). They worked the same way as I assigned independent variable x to them when I tried to do Curve Fitting; no problem found. So what is the difference between "x" and "num"? Thanks.
It might not answer your whole question, but I should point out that "x" is a function in IGOR as well :-), it allows one to access the scaling of a wave in an expression. For example the following expression would fill each point in the ypoints wave with a value that was calculated from the digamma function, using the x scaling at that point.
Wave ypoints
ypoints=digamma(x)
Try typing Displayhelptopic"x" for more information. You could do exactly the same thing with the gamma function:
Wave ypoints
ypoints=gamma(x)
THe use of any inbuilt function name as a local variable should be avoided, viz. x,y,p,q,r,s,z,t.
I am confused about the notations (x) and (num) in Volume V "Reference" of IgorMan.pdf. For example, I don't see any difference between the properties of the variables of the built-in operations digamma(x) and gamma(num). They worked the same way as I assigned independent variable x to them when I tried to do Curve Fitting; no problem found. So what is the difference between "x" and "num"? Thanks.
In this case I think the difference is in the authorship of the particular documentation involved. The function gamma() has been in Igor for a long time, and was probably written by Larry, Howard, or Jim. The digamma() function was added recently by AG. In this case, the use of "x" as the built-in function to access the X index during a wave assignment is a red herring.
Thank you. I have done a lot of wave scaling with x, too. I think the manual uses different variable notations x and num for digamma and gamma for a reason, but I have not figured the reason out...
(Oh, thank you for the clarification, johnweeks. I did not see your reply until I posted mine.)
Wave ypoints
ypoints=digamma(x)
Try typing
Displayhelptopic "x"
for more information. You could do exactly the same thing with the gamma function:Wave ypoints
ypoints=gamma(x)
THe use of any inbuilt function name as a local variable should be avoided, viz. x,y,p,q,r,s,z,t.
August 11, 2008 at 02:17 pm - Permalink
In this case I think the difference is in the authorship of the particular documentation involved. The function gamma() has been in Igor for a long time, and was probably written by Larry, Howard, or Jim. The digamma() function was added recently by AG. In this case, the use of "x" as the built-in function to access the X index during a wave assignment is a red herring.
We should be more consistent...
John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
August 12, 2008 at 10:42 am - Permalink
(Oh, thank you for the clarification, johnweeks. I did not see your reply until I posted mine.)
August 12, 2008 at 11:00 am - Permalink