Quantcast

Documentation Center

  • Trial Software
  • Product Updates

Contents

Inspect Signal Data

Overview

On the Inspect Signals tab you can inspect logged signal data. On the left pane you can open the Signal Browser table to view and configure signal and run properties (see Customize the Simulation Data Inspector Interface). On the right pane you can create different plot views. With a view of multiple plots, you can group signals to better view your data. For example, you can group the same signal from different simulation runs, group signals with a similar range of values, or normalize a subset of your signal data. The following examples use the slexAircraftExample model.

View Signal Data

  1. Configure a model to log signal data. This example uses the slexAircraftExample model. To log signals q, rad/sec, Stick, and alpha, rad, right-click each signal and select Properties. Select the Log signal data check box, and click OK.

  2. Double-click the Pilot signal generator block. Set the Wave form to sine, and click OK.

  3. In the Simulink Editor, click the Record button arrow, and select Simulation Data Inspector.

  4. To record simulation data, click the Record button on.

  5. Simulate the model. The Simulation Data Inspector records and displays the simulation data. Instead of recording data from a simulation, you can import signal data from previous simulation runs, see Import Logged Signal Data.

  6. By default, the Inspect Signals tab displays the Signal Browser table, which contains a row for each signal, organized by simulation runs. You can expand or collapse any of the runs to view the logged signals in a run. For more information, see Customize the Simulation Data Inspector Interface.

  7. Set up the columns of information to view about each signal. Right-click the Signal Browser table title bar and select Columns from the context menu. Select Block Name, Signal Name, and Line, clearing all other options.

  8. Right-click the Signal Browser table title bar, and select Group Signals. In the Group Signals dialog box, set the first Then By parameter to Logged Variable, and then click OK.

  9. Expand logsout and each signal in that group to view the logged signals.

  10. Select the check box next to each signal you want to plot. On the right pane of the Simulation Data Inspector, the signal data is displayed in the graph.

  11. To create a report of the results, see Create Simulation Data Inspector Report.

Create a View of Multiple Plots

Before creating a view of multiple plots, the Simulation Data Inspector must contain signal data. You can obtain signal data by either recording simulation data or importing data into the Simulation Data Inspector. For more information, see Record Simulation Data or Import Logged Signal Data.

  1. On the right pane, on the View toolbar, click Show Details.

  2. In the View Name column, click the field which displays Default. Type in a new name for the view. In this example, the name is plot4.

  3. In the Layout column, click the field that displays 1x1. A plot matrix opens. To create a view of 4 plots, select the 2x2 matrix.

  4. To select a plot, click it. The selected plot is outlined in blue.

  5. Once a plot is selected, on the left pane in the Signal Browser table, select a signal in the Plot column to add to the selected plot. In this example, a signal from Run 1 is displayed in each plot in the plot4 view.

    For the selected plot [2,2], the signal or signals are shaded in the Inspect Signals table to indicate which signals are in the selected plot.

Explore Signal Data in a Multiple Plot View

Linked Plots in a View

Plots within a view can be linked together to enable synchronized panning and zooming. When you create a view, by default, plots in a view are linked together. The following toolbar operations synchronize across linked plots:

  • Pan along the time axis:

  • Zoom on the time axis:

  • Zoom on the time and data value axis:

  • Zoom out:

To determine if a plot in a view is linked, at the top of each plot, locate the link icon . If a plot is unlinked, the broken link icon is displayed and the plot pans and zooms independently.

Move Signals Between Plots in a View

To move a signal from one plot to another, click and hold a signal (markers appear).

Drag the signal to another plot, and the signal is now displayed in the other plot.

For more information on working with plots, see Modify a Plot in the Simulation Data Inspector.

Replace a Run in a View

In this example, the Simulation Data Inspector contains three runs of data. To quickly swap out the data from one run with data from another run, do the following:

  1. Select a view. In this example, the view is plot4.

  2. Click Replace runs..., which opens the Replace runs dialog box.

  3. To replace the signal data in Run 2 with the signal data from another run, in the Runs in current view list, select Run 2. Only the signals in the view are replaced.

  4. In the Replace with list, select Run 3.

  5. To specify how the signal data in Run 2 is replaced with Run 3, expand Advanced options. In this example, the Simulation Data Inspector first attempts to align the signals by Data Source, then by Block Path, and lastly by Signal Name. For more information on aligning signals, see How the Simulation Data Inspector Aligns Signals.

  6. Click OK. The data from Run 2 is replaced with data from Run 3.

    The View Details table now includes Run 3 instead of Run 2. Run 3 lists signals from Run 2. The Match column displays a for a signal that aligned with a signal in Run 3. If a signal did not align, the Match column displays a .

Copy a View in the Inspect Signals Tab

To copy a view:

  1. On the right pane, in the View toolbar, click Show Details to open the View Details table.

  2. Select the view to copy. Be sure to select the option button next to the View Name in the table.

  3. Click the New View From Current button. A new view is displayed in the View Details table

  4. Select the new view, Copy of plot4, and rename it.

Delete a View in the Inspect Signals Tab

To delete a view:

  1. On the right pane, in the View toolbar, click Show Details to open the View Details table.

  2. In the View Details table, select the view to delete by selecting the corresponding option button.

  3. Click the Delete View button.

      Note:   The View Details table always includes one view.

Export a View in the Inspect Signals Tab

To export a view to a MAT-file:

  1. On the right pane, in the View toolbar, click Show Details to open the View Details table.

  2. Click the Export button and specify a file.

  3. This saves the view, but not the data, into a MAT-file. To save the data and the view, see Export Results in the Simulation Data Inspector.

Import a View in the Inspect Signals Tab

To reload a saved view from a MAT-file:

  1. On the right pane, in the View toolbar, click Show Details to open the View Details table.

  2. Click the Import button and specify a file.

      Note:   This only imports the configuration of the view, which is how the signal data is plotted among the multiple plots. The actual signal data is not imported.

  3. To include signal data in the Simulation Data Inspector, you can record simulation data (see Record Simulation Data), or import data (see Import Logged Signal Data).

Was this topic helpful?