Main Content

mcrversion

Return the MATLAB Runtime version number matching the version of MATLAB

Description

example

[major,minor] = mcrversion returns the MATLAB® Runtime version number matching the version of MATLAB from where the command is executed. The MATLAB Runtime version number consists of two digits, separated by a decimal point. This function returns each digit as a separate output variable: major, minor.

If the version number ever increases to three or more digits, call mcrversion with more outputs, as follows:

[major, minor, point] = mcrversion;
At this time, all outputs past “minor” are returned as zeros.

Output Arguments

collapse all

Major version number returned as a positive integer scalar.

Data Types: double

Minor version number returned as a positive integer scalar.

Data Types: double

Examples

collapse all

[major, minor] = mcrversion
major =
     9
minor =
     9
Introduced in R2008a