cdflib.getVarReservePercent
Compression reserve percentage for variable
Syntax
percent = cdflib.getVarReservePercent(cdfId,varNum)
Description
percent = cdflib.getVarReservePercent(cdfId,varNum)
returns the compression reserve percentage for a variable in a Common
Data Format (CDF) file. This operation only applies to compressed
variables.
cdfId
identifies the CDF file. varNum
is
a numeric value that identifies the variable. Variable numbers are
zero-based.
Examples
Open the example CDF file, get the number of a compressed variable, and then determine the reserve percent for the variable.
cdfId = cdflib.open("example.cdf"); varnum = cdflib.getVarNum(cdfId,"Temperature"); percent = cdflib.getVarReservePercent(cdfId,varnum)
percent = 0
% Clean up cdflib.close(cdfId) clear cdfId
More About
Tips
This function corresponds to the CDF library C API routine
CDFgetzVarReservePercent
.To use this function, you must be familiar with the CDF C interface. You can access the CDF documentation at the CDF website.