cvresults - Returns active coverage data, clears and loads active coverage data from a
file - MATLAB ([original](https://in.mathworks.com/help/slcoverage/ref/cvresults.html)) ([raw](?raw))
Main Content
Returns active coverage data, clears and loads active coverage data from a file
Syntax
Description
[[covData](#mw%5F136ec0fb-4f37-42d5-b922-9cd7b66f88ce),[cumulativeCovData](#mw%5F0e45119f-8239-4715-93dd-e1257a3b2880)] = cvresults([modelName](#mw%5F8d7f4031-b0d6-4fb7-b819-9014c4fb9a7e))
returns the active single-run coverage data covData
and cumulative coverage data cumulativeData
.
cvresults([modelName](#mw%5F8d7f4031-b0d6-4fb7-b819-9014c4fb9a7e),'clear')
clears the active coverage data.
cvresults([modelName](#mw%5F8d7f4031-b0d6-4fb7-b819-9014c4fb9a7e),'load',[fileName](#mw%5Fd5f4bc00-32d5-474d-b83e-ab0b37f32e27))
loads the active coverage data from a .cvt
file.
Examples
- Simulate your model and collect coverage.
- Get the current coverage data.
[covData,cumulativeCovData] = cvresults(modelName);
Input Arguments
Model name, specified as a character array or string array.
Data Types: char
| string
Coverage data file name, specified as a character array or string array.
Data Types: char
| string
Output Arguments
Coverage data, returned as a cvdata
object.
Data Types: cvdata
Cumulative coverage data, returned as a cvdata
object.
Data Types: cvdata
Version History
Introduced in R2016a