| Contents | Index |
| On this page… |
|---|
Loading Data into the MATLAB Workspace Opening the System Identification Tool GUI |
Load the data in dryer2.mat by typing the following command in the MATLAB Command Window:
load dryer2
This command loads the data into the MATLAB workspace as two column vectors, u2 and y2, respectively. The variable u2 is the input data and y2 is the output data.
To open the System Identification Tool GUI, type the following command in the MATLAB Command Window:
ident
The default session name, Untitled, appears in the title bar.

You can import the single-input/single-output (SISO) data from a sample data file dryer2.mat into the GUI from the MATLAB workspace.
You must have already loaded the sample data into MATLAB, as described in Loading Data into the MATLAB Workspace, and opened the System Identification Tool GUI, as described in Opening the System Identification Tool GUI.
If you have not performed these steps, click here to complete them.
To import data arrays into the System Identification Tool GUI:
In the System Identification Tool GUI, select Import data > Time domain data. This action opens the Import Data dialog box.

Specify the following options:
Input — Enter u2 as the name of the input variable.
Output — Enter y2 as the name of the output variable.
Data name — Change the default name to data. This name labels the data in the System Identification Tool GUI after the import operation is completed.
Starting time — Enter 0 as the starting time. This value designates the starting value of the time axis on time plots.
Sampling interval — Enter 0.08 as the time between successive samples in seconds. This value is the actual sampling interval in the experiment.
The Import Data dialog box now resembles the following figure.

In the Data Information area, click More to expand the dialog box. Enter the settings shown in the following figure.

Input Properties
InterSample — Accept the default zoh (zero-order hold) to indicate that the input signal was piecewise-constant between samples during data acquisition. This setting specifies the behavior of the input signals between samples when you transform the resulting models between discrete-time and continuous-time representations.
Period — Accept the default inf to specify a nonperiodic input.
Channel Names
Input — Enter power.
Output — Enter temperature.
Physical Units of Variables
Input — Enter W for power units.
Output — Enter ^oC for temperature units.
Notes — Enter comments about the experiment or the data. For example, you might enter the experiment name, date, and a description of experimental conditions. When you estimate models from this data, these models inherit your data notes.
Click Import to add the icon named data to the System Identification Tool GUI.

Click Close to close the Import Data dialog box.
In this portion of the tutorial, you evaluate the data and process it for system identification. You learn how to:
Plot the data.
Subtract the mean values of the input and the output to remove offsets.
Split the data into two parts. You use one part of the data for model estimation, and the other part of the data for model validation.
The reason you subtract the mean values from each signal is because, typically, you build linear models that describe the responses for deviations from a physical equilibrium. With steady-state data, it is reasonable to assume that the mean levels of the signals correspond to such an equilibrium. Thus, you can seek models around zero without modeling the absolute equilibrium levels in physical units.
You must have already imported data into the System Identification Tool, as described in Importing Data Arrays into the System Identification Tool.
If you have not performed this step, click here to complete it.
To plot and process the data:
In the System Identification Tool GUI, select the Time plot check box to open the Time Plot. If the plot window is empty, click the data icon in the System Identification Tool GUI.

The top axes show the output data (temperature), and the bottom axes show the input data (power). Both the input and the output data have nonzero mean values.
In the System Identification Tool GUI, select <--Preprocess > Remove means to subtract the mean input value from the input data and the mean output value from the output data.

This action adds a new data set to the System Identification Tool GUI with the default name datad (the suffix d means detrend), and updates the Time Plot window to display both the original and the detrended data. The detrended data has a zero mean value.

In the System Identification Tool GUI, drag the datad data set to the Working Data rectangle. This action specifies the detrended data to be used for estimating models.

Select <--Preprocess > Select range to open the Select Range window.
In this window, you can split the data into two parts and specify the first part for model estimation, and the second part for model validation, as described in the following steps.
In the Select Range window, change the Samples field to select the first 500 samples, as follows:
1 500

In the Data name field, type the name estimate, and click Insert. This action adds a new data set to the System Identification Tool GUI to be used for model estimation.
In the Select Range window, change the Samples field to select the last 500 samples, as follows:
501 1000

In the Data name field, type the name validate, and click Insert. This action adds a new data set to the System Identification Tool GUI to be used for model validation.
Drag and drop estimate to the Working Data rectangle, and drag and drop validate to the Validation Data rectangle so that the System Identification Tool GUI resembles the following figure.

To get information about a data set, right-click its icon. For example, right-click the estimate data set to open the Data/model Info dialog box.

In the Data/model Info dialog box, you can perform the following actions:
Change the name of the data set in the Data name field.
Change the color of the data icon by changing the RGB values (relative amounts of red, green, and blue). Each value is between 0 and 1. For example, [1,0,0] indicates that only red is present, and no green and blue are mixed into the overall color.
In the noneditable area, view the total number of samples, the sampling interval, and the output and input channel names and units.
In the editable Diary And Notes area, view or edit the actions you performed on this data set. The actions are translated into commands equivalent to your GUI operations. For example, as shown in the Data/model Info: estimate window, the estimate data set is a result of importing the data, detrending the mean values, and selecting the first 500 samples of the data:
% Import data datad = detrend(data,0) estimate = datad([1:500])
For more information about these and other toolbox commands, see the reference page corresponding to each command.
Tip As an alternative shortcut, you can select Preprocess > Quick start from the System Identification Tool GUI to perform all of the data processing steps in this tutorial. |
For information about supported data processing operations, such as resampling and filtering the data, see the System Identification Toolbox User's Guide.
![]() | About This Tutorial | Saving the GUI Session | ![]() |

Learn more about resources for designing, testing, and implementing control systems.
Get free kit| © 1984-2012- The MathWorks, Inc. - Site Help - Patents - Trademarks - Privacy Policy - Preventing Piracy - RSS |