Macro commands may be used either in macros or by sending the commands to DPlot via dynamic data exchange (DDE). Some commands are valid only in macros (noted by Macros Only). Commands sent to DPlot via DDE must be enclosed by square brackets [     ]. Macro commands should not include the brackets.

Command parameters shown in the descriptions below are placeholders for the actual values. Command parameters are either numeric values, equations that evaluate to numbers, or character strings. Character string parameters are always bound by double quotation marks. Equations must be preceded by an equals sign (=).

The pipe symbol (|) in the command syntax indicates that a parameter is optional, and should not be included in your macro unless otherwise noted.

All indices into arrays are 1-based, e.g. Curve1=1 refers to the first curve in a plot.

A 0x prefix for numbers in the descriptions below indicates hexadecimal notation; e.g. 0x0010 = 16.

JR/Viewer indicates that the command is supported by DPlot Jr or DPlot Viewer.
JR/Viewer indicates that the command is NOT supported by DPlot Jr or DPlot Viewer.


[EditFilter("user",passes,replace,C0,C1,C2,D1,D2)] or                

[EditFilter("bandpass",passes,replace,freq1,freq2|,timeunits|,stop_or_pass||)] or

[EditFilter("optionX",passes,replace)] or


JR   Viewer

Applies a digital filter to the curve most recently selected with the SelectCurve command.

“USER” filter: C0, C1, C2, D1, and D2 are the coefficients of the filter equation to be used (described in the Filter topic).

“BANDPASS” filter: If stop_or_pass is 0 or omitted and freq1 is a positive number, then freq1 is the frequency to remove from the data record and freq2 is the bandwidth, or width of the notch, to remove. If freq2 is equal to 0 then the Carleton method is used;h otherwise the Press method is used. If freq1 is equal to 0, the zero frequency rejection filter is used and freq2, timeunits, and stop_or_pass are ignored. If stop_or_pass is non-zero, then freq1 specifies the lower cutoff frequency and freq2 specifies the upper cutoff frequency. To implement a low-pass filter, set freq1 to 0; to implement a high-pass filter set freq2 to a very high frequency.
timeunits indicates the units of time for the input X values. If 0 or omitted, seconds are assumed. Set to 1 for milliseconds, 2 for microseconds.

“OPTIONX” filter: X must be one of 1, 2, 3, or 4 and corresponds to the filters described in the Filter topic.

"CFCX" filter: X must be one of 60, 180, 600, or 1000 and corresponds to the filters described in the Filter topic. Time units are determined by the X axis label. If the label includes the characters "msec" or "millisec", milliseconds are assumed. If the label includes "microsec" then microseconds are assumed. Otherwise seconds are assumed.

Passes is a misnomer for historical reasons and is one less than the number of passes through the data. The operation is performed in forward, reverse, forward, reverse, etc. order. So if passes is 0, 2, 4, etc. the operation will end in a forward pass. If 1, 3, 5, etc. the operation ends with a time-reversed pass.

If replace is non-zero, then the original data set is replaced by the filtered data. If replace is equal to 0, then the original data is preserved.


See also

Filter menu command


Page url: