$LastChangedDate: 27-Juil-2011 $

# CL_autoLevels

Automatic generation of level values

## Calling Sequence

       [levels, sublevels] = CL_autoLevels(vmin, vmax, ns1, ns2)

## Description

- Generates sensible level values than can be used for contour plots.

  The numbers of levels or sublevels returned are never equal to 1 (so that contour2d doesn't confuse the level values with the number of values).

  The intersection between levels and sublevels is empty: there are no values belonging both to levels and sublevels.

## Parameters

vmin:

  User data minimum value.

vmax:

  User data maximum value.

ns1:

  (optional) Approximate number of steps. Default is 7.

ns2:

  (optional) Approximate number of sub-steps. Default is 5.

levels:

  Level values.

sublevels:

  Sub-level values.

## Authors

- CNES - DCT/SB (AL)

## See also

- CL_graduate

## Examples

    [levels, sublevels] = CL_autoLevels(0, 6)
    [levels, sublevels] = CL_autoLevels(1.14, 2.27, 5, 5)