필터 지우기
필터 지우기

Model Advisor - Is is possible to obtain the number of individual violations?

조회 수: 2 (최근 30일)
Would like to obtain, as a metric on the project I am working on, the number of individual violations when running a Model Advisor configuration.
For example, in the case below I would like to obtain the value 5 (ideally per MA Check), as there are 5 individual violations (the blue highlights) preventing the check to be a PASS.

채택된 답변

Poorna
Poorna 2024년 5월 6일
Hi Marcelo,
I see you want to get the number of occurences of violations of a check in your model. As per the above case you are looking specifically the list of blocks that do not pass the "Unconnected lines and ports" check.
It is to be noted that there are functions available to run the checks programmatically.
You can find the list of functions available here: https://www.mathworks.com/help/simulink/slref/simulink.modeladvisor.html
Of these functions you can use the "runCheck" function to run the desired check and then run the "getCheckResult" function to the result of the check. It is to be noted that the output format of the "getCheckResult" function depends on the check that is performed.
Hope this Helps!

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Run Model Advisor Checks에 대해 자세히 알아보기

제품


릴리스

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by