DAT_COERC
Coerce object shape
Description:
Temporarily coerce an object into changing its
shape.
Invocation
CALL DAT_COERC( LOC1, NDIM, LOC2, STATUS )
Arguments
LOC1 = CHARACTER
( DAT__SZLOC
) (Given)
NDIM = INTEGER (Given)
Number of dimensions.
LOC2 = CHARACTER
(
DAT__SZLOC ) (Returned)
Coerced object locator.
STATUS = INTEGER (Given and
Returned)
The global status.
Notes:
If the number of dimensions in the object is to be
increased, each additional dimension size is set to 1, e.g. if loc1 is associated with a 2-D
object of shape (512,256) say, setting ndim to 3 transforms the dimensions to (512,256,1).
Likewise, if the number of dimensions is to be reduced, the appropriate trailing dimension
sizes are discarded; the routine will fail if any of these do not have the value 1. As with
DAT_VEC, only the appearance of the object is changed – the original shape remains intact.
Copyright © 2019 East Asian Observatory