Explore Traceability Information for Units and Components
Explore traceability relationships for design artifacts, requirements, tests, and results in your software units and components by using trace views in the dashboard. A trace view is an interactive diagram that shows a certain preset of traceability information for artifacts in a project. Trace views provide a detailed, tree-like structure of project artifacts and show trace relationships, individual artifact information, and a hierarchical view of trace relationships between the artifacts in a unit or component.
This example shows how to use trace views to see how artifacts trace to units and components in your design and view the traceability information for requirements, tests, and test results in the project. You can access these trace views from any open Dashboard window in the View section of the toolstrip:
Requirement to Design
Tests and Results
The trace views provide traceability information within the context of software units and components in a project. To find required files for a whole project or to find required products and add-ons, use the Dependency Analyzer. For more information, see Analyze Project Dependencies.
Access Trace Views
Open the MATLAB® Project that you want to analyze. For example, to open a copy of the dashboard example project, in the MATLAB Command Window, enter:
Open a dashboard. On the Project tab, click either:
Model Testing Dashboard
Model Design Dashboard
When you open a dashboard, the dashboard analyzes the project and collects information about the project artifacts, the artifact structure, and the traceability relationships between artifacts. The dashboard creates a digital thread that stores these attributes and unique identifiers for your project artifacts. The dashboard automatically populates the Artifacts panel with the artifacts that the digital thread traces to the software units and components in your project. For more information on the artifact analysis and tracing that the dashboard performs, see Digital Thread.
To open a trace view, first select a unit or component in the Project pane. For this example, select
cc_ControlMode. Then click Trace View in the Traceability section of the toolstrip.
If you do not see the units and components that you expect, see Categorize Models in a Hierarchy as Components or Units.
To navigate and explore the trace view:
Zoom in or out by using the scroll wheel on your mouse or by using the Zoom In and Zoom Out buttons in the Navigate section of the toolstrip.
Pan vertically and horizontally by holding the space bar and clicking and dragging the mouse.
Highlight the connection between artifacts by clicking the arrow between the artifacts. You can click an artifact or arrow to select it. You can also move the artifacts and arrows in the trace view to rearrange the diagram.
Open a new trace view tab for the next unit or component listed in the Project panel by clicking Add New in the toolstrip.
Reset the diagram to the original layout and zoom level by clicking Restore to Default in the toolstrip.
To view a tooltip with detailed information about an artifact, point to the artifact. You also see an Open Artifact button that you can use to open the artifact directly from the trace view.
By default, the dashboard opens the Design Dependency trace view, but you can use the other trace views to explore the traceability information for your project.
View Different Trace Views
View different traceability information by using the trace views gallery in the View section of the toolstrip. The gallery shows the names and descriptions of the trace views. Open a different trace view by clicking the name of a trace view in the trace views gallery. If a unit or component does not trace to any of the artifacts supported by the trace view that you select, select a different trace view from the trace views gallery.
Design Dependency Trace View
The Design Dependency trace view shows the library blocks, data dictionaries, model references, and MATLAB files that trace to the selected unit or component.
For example, the Design Dependency trace view for the
example software unit
cc_LightControl shows that the unit:
Contains the subsystem
Requires the three data dictionary files:
lib_BaseConfig.slda d, and
You can use the trace view to examine the relationships that the dashboard
identifies between design artifacts and to inspect component and unit
dependencies. If you point to lib_BaseConfig.sldd in the
trace view, the tooltip shows that this data dictionary file belongs to the
You can point to the arrow between artifacts to view the relationship type.
For example, the unit
cc_LightControl requires the data
cc_LightControl contains the subsystem
Requirement to Design Trace View
The Requirement to Design trace view shows the functional requirements that trace to the selected unit or component.
For example, the Requirement to Design trace view for the
example software component
cc_LightControl shows that 3
requirement links trace to 3 functional requirements:
control light indicator,
Show cruise control set
indicator light, and
Show cruise control light when
ignition switch is turned. The trace view shows that the dashboard
traced the relationship from the block diagram for the unit, to the requirement
link, and then to the functional requirement.
You can point to a functional requirement to see where the requirement is in the requirements hierarchy and use the Open Artifact button to open the requirement directly in the Requirements Editor.
Tests and Results Trace View
The Tests and Results trace view shows the test cases and test results that trace to the selected unit or component. The trace view shows the Simulink® Test™ files and test suites containing test cases that trace to the current unit or component. If you have test results associated with the test cases, the trace view traces those results to the test case and identifies whether the results are from model tests, software-in-the-loop (SIL) tests, or processor-in-the-loop (PIL) tests.
You can point to a Simulink Test case result and click Open Artifact to open the results directly in Test Manager.
Troubleshoot Missing Artifacts and Relationships
If you expect an artifact to appear in the trace view for a unit or component and it does not, see Resolve Missing Artifacts, Links, and Results.