User`s guide
1 Data Processing
Subtracting Trends from Signals (Detrending)
In this section...
“What Is Detrending?” on page 1-94
“When to Detrend Data” on page 1-94
“When Not to Detrend Data” on page 1-95
“GUI and Command-Line A lternatives for Detrending Data” on page 1-96
“How to Detrend Data U sing the GUI” on page 1-96
“How to D etrend Data at the Command Line” on page 1-97
“How to Add Detrended Values to the M odel Output” on page 1-98
What Is Detrending?
Detrending da ta rem o ve s mean values or linear trends from time-series and
input/output signals. If your data set includes multiple inputs and outputs,
detrending removes trends independently from each signal.
You can later restore the removed trend to simulated or predicted m odel
output, as described in “How to Add Detrended Values to the M odel Output”
on page 1-98.
For more information about handling drifts in the data, see the chapter on
preprocessing data in System Identification: Theory for the User,Second
Edition, by Lennart Ljung, Prentice Hall PTR, 1999.
To learn more about preparing your d ata for system identification, see “Ways
to Process Data for System Identification” on page 1-2.
When to Detrend Data
You might want to detrend data before performing system i denti fication, as
described in “Steps for Using This Too lbox ”. For example, y ou can rem ov e a
constant offset (zero-order trend) or drift (first-order, or linear, trend) from
your data before mode ling. R emov ing a trend from the data enables you to
focusyouranalysisonthefluctuations in the data about the trend.
1-94