plcont
( | f, |
nx, | |
ny, | |
kx, | |
lx, | |
ky, | |
ly, | |
clevel, | |
nlevel, | |
pltr, | |
pltr_data) ; |
Draws a contour plot of the data in
,
using the f
[nx
][ny
]
contour
levels specified by nlevel
.
Only the region of the matrix from
clevel
to
kx
and from
lx
to
ky
is plotted out where all
these index ranges are interpreted as one-based for historical
reasons. A transformation routine pointed to by
ly
with a generic pointer
pltr
for additional
data required by the transformation routine is used to map indices
within the matrix to the world coordinates.pltr_data
f
(PLFLT_MATRIX
, input)
A matrix containing data to be contoured.
nx, ny
(PLINT
, input)
The dimensions of the matrix
.
f
kx, lx
(PLINT
, input)
Range of x
indices to consider where
0 ≤ kx-1 < lx-1 < nx
. Values of
kx
and lx
are one-based rather
than zero-based for historical backwards-compatibility reasons.
ky, ly
(PLINT
, input)
Range of y
indices to consider where
0 ≤ ky-1 < ly-1 < ny
. Values of
ky
and ly
are one-based rather
than zero-based for historical backwards-compatibility reasons.
clevel
(PLFLT_VECTOR
, input)
A vector specifying the levels at which to draw contours.
nlevel
(PLINT
, input)
Number of contour levels to draw.
pltr
(PLTRANSFORM_callback
, input)
A callback function that defines the transformation
between the zero-based indices of the matrix
and the world coordinates.f
For the C case, transformation functions are provided
in the PLplot library: pltr0
for the identity mapping, and pltr1
and pltr2
for arbitrary mappings respectively defined by vectors and
matrices. In addition, C callback routines for the transformation can
be supplied by the user such as the mypltr
function
in examples/c/x09c.c
which provides a general
linear transformation between index coordinates and world
coordinates.
For languages other than C you should consult Part III, “ Supported computer languages ” for the details concerning how
PLTRANSFORM_callback
arguments are interfaced.
However, in general, a particular pattern of
callback-associated arguments such as a tr
vector
with 6 elements; xg
and yg
vectors; or xg
and yg
matrices
are respectively interfaced to a linear-transformation routine similar
to the above mypltr
function; pltr1
; and pltr2
.
Furthermore, some of our more sophisticated bindings (see, e.g., Chapter 10, Fortran Language) support native language callbacks for handling
index to world-coordinate transformations. Examples of these various
approaches are given in
examples/<language>x09*
,
examples/<language>x16*
,
examples/<language>x20*
,
examples/<language>x21*
, and
examples/<language>x22*
, for all our
supported languages.
pltr_data
(PLPointer
, input)
Extra parameter to help pass information to pltr0
, pltr1
,
pltr2
, or whatever callback routine that is externally
supplied.
Redacted form: plcont(f, kx, lx, ky, ly, clevel,
pltr, pltr_data)
where (see above discussion) the
pltr, pltr_data
callback arguments are sometimes replaced
by a tr
vector with 6 elements; xg
and yg
vectors; or xg
and yg
matrices.
This function is used in examples 9, 14, 16, and 22.