DSPPeriodogram ignores range flag if segment flag is used
hiller
The syntax of the function is
DSPPeriodogram [/dB /dBR=ref /COHR /DLSG /NODC=val /NOR=value /Q /SEGN={ptsPerSegment , overlapPts } /R=[start, end ] /R=(startX, endX) /WIN=windowKind /Z ] srcWave [, srcWave2 ]
The /R flag is a typical range flag, either by point number [] or by x-value (). If the /SEGN flag is not used, the function respects the range flag, and only operates on that part of the source wave.
However, if the /SEGN flag is used, then the entire source wave is used, regardless of the presence or contents of the /R range flag. I expected that the range flag would limit the operation to part of the source wave, if the /SEGN flag is used.
To reproduce:
•make/n=100001 aa
•dspperiodogram/SEGN={1024,0} aa
Evaluating the periodogram using 98 segments
•dspperiodogram/SEGN={1024,0}/R=[0,50001] aa
Evaluating the periodogram using 98 segments
•dspperiodogram/SEGN={1024,0}/R=[0,1] aa
Evaluating the periodogram using 98 segments
This is not a bug; the /SEGN flag is intended to work on the full input so when you use it, the /R flag is ignored.
I'll make sure that this is stated explicitly in the documentation.
A.G.
WaveMetrics, Inc.
August 27, 2012 at 09:58 am - Permalink
Since the documentation at this point is ambiguous, you can choose which way to resolve this. And I'd humbly suggest that you add this capability for those who need it, and which doesn't affect other users.
August 27, 2012 at 06:04 pm - Permalink
A.G.
WaveMetrics, Inc.
August 28, 2012 at 04:54 pm - Permalink
A.G.
WaveMetrics, Inc.
August 30, 2012 at 11:49 am - Permalink
I'm confused - the current beta lists June 19 as the build date. Do you mean the latest Igor nightly build?
August 30, 2012 at 11:58 am - Permalink
The change, which has been requested by several customers has already been implemented and is available in the beta. Obviously it is also available in the nightly build. The OP reported using 6.2.2.2 so I think they would benefit more from the beta which is a complete package as opposed to updating only the application.
A.G.
WaveMetrics, Inc.
August 30, 2012 at 03:30 pm - Permalink