Resample time-domain data by decimation or interpolation
datar = idresamp(data,[P Q])
datar = idresamp(data,R)
datar = idresamp(___,
[datar,res_fact] = idresamp(___)
idresamp resamples time-domain data using two different
methods, one which uses Signal Processing Toolbox™ and one which does not.
If you have Signal Processing Toolbox, it is recommended that you use one of the syntaxes that has
[P,Q]as the second argument . The software automatically uses the resampling algorithm from that toolbox.
If you do not have Signal Processing Toolbox, then the software automatically uses the resampling algorithm from System Identification Toolbox™ regardless of which syntax you use.
datar = idresamp(data,[P Q]) resamples the data
Q times the
original sample rate and returns the resampled data as
data can be a timetable, a comma-separated pair of numeric
matrices, or an
iddata object. The algorithm takes into
account the intersample characteristics of the input signal that are described by the
InputInterSample property in
datar = idresamp(data,R) resamples
data using a sample
time that is a factor
R of the original sample interval. This syntax
does not require Signal Processing Toolbox
datar = idresamp(___, incorporates an
opt that specifies options in
idresampOptions such as filter order, rational approximation tolerance,
and input intersample behavior. You can use this syntax with any of the previous
[datar,res_fact] = idresamp(___) returns
res_fact, which corresponds to the value of
approximated by a rational expression.
Time-domain signal data.
datacan be uniformly sampled input-output or time-series data in the form of a timetable, a comma-separated pair of numeric matrices u,y, or an
Vector of two positive integers that represent the interpolation and decimation factors that combine to form the sample rate multiplier
Q(or equivalently, the sample time multiplier
P> 1 results in decimation and setting
P< 1 results in interpolation.
Resampling options, specified as an
Name of the resampled data variable.
datarhas the same format (timetable, matrix or data object) as
Rational approximation for the specified resampling factor
Any positive number you specify is replaced by the rational approximation,
P, where the data is interpolated by a factor
Pand then decimated by a factor
Version HistoryIntroduced in R2007a
idresamp incorporates functionality of
R2022b: Time-domain estimation data is accepted in the form of timetables and matrices
Most estimation, validation, analysis, and utility functions now accept time-domain
input/output data in the form of a single timetable that contains both input and output data
or a pair of matrices that contain the input and output data separately. These functions
continue to accept
iddata objects as a data source as well, for
both time-domain and frequency-domain data.