Documentation

slmetric.metric.Metric class

Package: slmetric.metric
Superclasses:

Abstract class for creating model metrics

Description

Abstract base class for creating model metrics. To create a model metric, create a MATLAB® class that derives from the slmetric.metric.Metric class.

Properties

expand all

Compile mode for metric calculation. If your model metric requires model compilation, specify PostCompile. If your model metric does not require model compilation, specify None.

Example: 'PostCompile'

Data Types: char

Model components for which metric is calculated. The metric is calculated for all components that match the type.

Metric description.

Data Types: char

Unique metric identifier.

Data Types: char

Use this property to communicate changes in your metric algorithm to the metric engine.

Data Types: uint32

Specify a name for the custom metric algorithm.

Data Types: char

If true, results produced by the metric algorithm change only if the model or library source files change. If the source file and the metric Version have not changed, metric data is not regenerated. If false, each call to slmetric.Engine.execute collects new data for this metric and stores it in the metric repository.

Data Types: logical

Specify the operation to aggregate the slmetric.metric.Result object properties Value and Measure across the component hierarchy. The metric algorithm outputs the aggregated values in the slmetric.metric.Result object properties AggregatedValues and AggregatedMeasures. Options are:

  • Sum: Returns the sum of the Value property and the Value properties of all its children components across the component hierarchy.

  • Max: Returns the maximum of the Value property and the Value properties of all its children components across the component hierarchy.

  • None: No aggregation of metric values.

Data Types: char

If true, metric results that do not cover the full component scope are aggregated to the component level. Values and measures of the detailed results belonging to a component are summed and a new result is created that spans the complete component.

If false, returns the detailed results of the component. Detailed results are not aggregated.

Data Types: logical

Specify whether the slmetric.metric.Result object property Details contains data. The default value is false.

Data Types: logical

Methods

algorithmSpecify logic for metric data analysis

Introduced in R2016a

Was this topic helpful?