x2pnt vs FindValue
rhjpires
I'm a bit confused with the usage of
x2pnt
and its relationship with FindValue
.In the past I have been able to use
x2pnt
to delimit a region of a wave to be fitted by an equation and all worked good.Today, when attempting to use
x2pnt
again in another procedure I still cannot understand the output I was getting.For example, for a random wave with n number of points, every time I tried to print
x2pnt(wavename, xvalue)
, instead of printing out the point/position of the xvalue on the wave, I just got xvalue itself. I ended up going for FindValues
which worked fine.What am I missing here? Is there any limitation in the use of x2pnt that I am not considering? the documentation seems quite trivial about it.
What is the difference between the two functions in terms of usage?
Thanks in advance.
R.
PS: Incidentally,
pnt2x
was also printing the point number rather than the xvalue.
March 17, 2017 at 08:48 am - Permalink
what does
say?
HJ
March 17, 2017 at 08:50 am - Permalink
March 17, 2017 at 10:58 am - Permalink
Many thanks to the input guys!!
Cheers,
R.
March 17, 2017 at 02:09 pm - Permalink
Could you share the basic concept of your solution to others with a similar issue?
HJ
March 17, 2017 at 05:53 pm - Permalink
x2pnt
would work only on xwaves. TheDisplayHelpTopic "x2pnt"
treats it very trivially and the lack of an error message also did not help. My former use of the function was incidentally on waveforms, so I did not encounter this problem back then, and was now a bit confused. Many thanks again for the help.Cheers,
R.
March 18, 2017 at 06:53 am - Permalink
Also, the guided tour section "Waves - The Key Igor Concept" covers much of the same material. If you have not done the guided tour, choose Help->Getting Started. It is essential for understanding Igor.
March 18, 2017 at 10:23 am - Permalink