Average Strict Modified Essential Complexity is one of the source-code metrics Understand computes across 17+ languages — browse them in the GUI, export and track them, or script them with the Python API.
Average Strict Modified Essential Complexity
API ID: AvgEssentialStrictModifiedLanguages: Ada
Targets: Architectures, Files, Packages, Project
Average strict modified essential complexity for all nested functions or methods.
For example:
package Essential_Demo is
procedure Simple_Proc (X : in out Integer);
function Strict_Func (A, B : Boolean; N : Integer) return Integer;
function Case_Func (Day : Integer) return Integer;
function Mixed_Func (A, B : Boolean; Day : Integer) return Integer;
end Essential_Demo;
Simple_Proc, Strict_Func, Case_Func, and Mixed_Func have Strict Modified Essential Complexity of 1, 5, 2, and 7. For the Essential_Demo package, the average is (1 + 5 + 2 + 7) / 4 = 3.75, rounded to 4.
See Sum and Max Strict Modified Essential Complexity for the other aggregations.
Targets By Language:- Ada: Project, File, Package
- For projects and architectures, this metric must also be enabled from "Project Configuration/Metrics/Projects and Architectures" with the "Show aggregated function metrics" option.
- This metric can be enabled from "Project Configuration/Metrics/Complexity" with the "Essential" option.