Skip to main content

WaveInfo

WaveInfo (wave, )

The WaveInfo function returns a string containing a semicolon-separated list of information about the given wave.

The second parameter is reserved for future use and must be zero.

A null wave reference returns a zero-length string. This might be encountered, for instance, when extracting wave names from a list using the StringFromList function, when the last wave name has been extracted from the list.

Details

The result string contains a list of keyword-value pairs. Each pair consists of a keyword, a colon, the value text, and a semicolon.

Here are the keywords:

KeywordInformation Following Keyword
DUNITSThe wave's data units.
FULLSCALEThree numbers indicating whether the wave has any data full scale information, and the min and max data full scale values.
The format of the FULLSCALE description is:
FULLSCALE:validFS, minFS, maxFS ;
validFS is 1 if minFS and maxFS have been set via a SetScale d command; otherwise it is 0.
LOCKReads back the value set by SetWaveLock.
MODIFIED1 if the wave has been modified since the experiment was last saved, else 0.
MODTIMEThe date and time that the wave was last modified in seconds since January 1, 1904.
NUMTYPEA number denoting the data type of the wave.
For text waves this is 0.
For wave reference waves it is 16384.
For data folder reference waves it is 256.
For numeric waves it is one of the following:
1:Complex, added to one of the following:
2:32-bit (single precision) floating point
4:64-bit (double precision) floating point
8:8-bit signed integer
16:16-bit signed integer
32:32-bit signed integer
64:Unsigned, added to 8, 16, 32 or 128 if wave is unsigned
128:64-bit signed integer
For example, the number denoting a complex double precision wave is 5 (1+4).
PATHThe name of the symbolic path in which the wave file is stored (e.g., PATH:home;) or nothing if there is no path for the wave (PATH:;).
SIZEINBYTESThe total size of the wave in bytes. This includes the wave's header, data, note, dimension labels, and unit strings. This keyword was added in Igor Pro 7.00.
XUNITSThe wave's x units.

Always pass 0 as the second input parameter. In future versions of Igor, this parameter may request other kinds of information to be returned.

A null wave reference returns a zero-length string. This might be encountered, for instance, when using WaveRefIndexedDFR in a loop to act on all waves in a data folder, and the loop has incremented beyond the highest valid index.

Examples

Make/O wave1;SetScale x,0,1,"dyn",wave1;SetScale y,3,20,"v",wave1
String info = WaveInfo(wave1,0)
Print NumberByKey("NUMTYPE", info) // Prints 2
Print StringByKey("DUNITS", info) // Prints "v"

See Also

The functions and operations listed under "About Waves" categories in the Command Help tab of the Igor Help Browser; among them are CreationDate, ModDate, WaveModCount, WaveType, note, and numpnts.

WaveInfo lacks information about multidimensional waves. Individual functions are provided to return dimension-related information: DimDelta, DimOffset, DimSize, WaveUnits, GetDimLabel.

For an explanation of waves and wave scaling, see The Waveform Model of Data.