| setFlags {oce} | R Documentation |
Set Data-Quality Flags within a oce Object
Description
This function changes specified entries in the data-quality
flags of a oce object, which are stored within
a list named flags that resides in the metadata
slot. If the object already has a flag set up for name,
then only the specified entries are altered. If not, the flag
entry is first created and its entries set to default,
after which the entries specified by i
are changed to value.
The specification is made with i, the form of which
is determined by the data item in question. Generally,
the rules are as follows:
If the data item is a vector, then
imust be (a) an integer vector specifying indices to be set tovalue, (b) a logical vector of length matching the data item, withTRUEmeaning to set the flag tovalue, or (c) a function that takes anoceobject as its single argument, and returns a vector in either of the forms just described.If the data item is an array, then
imust be (a) a data frame of integers whose rows specify spots to change (where the number of columns matches the number of dimensions of the data item), (b) a logical array that has dimension equal to that of the data item, or (c) a function that takes anoceobject as its single input and returns such a data frame or array.
See “Details” for the particular case of oce objects.
Usage
setFlags(object, name = NULL, i = NULL, value = NULL, debug = 0)
Arguments
object |
An oce object. |
name |
Character string indicating the name of the variable to be flagged. If
this variable is not contained in the object's |
i |
Indication of where to insert the flags; see “Description” for general rules and “Details” for rules for oce objects. |
value |
The value to be inserted in the flag. |
debug |
Integer set to 0 for quiet action or to 1 for some debugging. |
Details
This generic function is overridden by specialized functions for some object classes.
Value
An object with flags set as indicated.
See Also
Other functions relating to data-quality flags:
defaultFlags(),
handleFlags,adp-method,
handleFlags,argo-method,
handleFlags,ctd-method,
handleFlags,oce-method,
handleFlags,section-method,
handleFlags(),
initializeFlagScheme,ctd-method,
initializeFlagScheme,oce-method,
initializeFlagScheme,section-method,
initializeFlagSchemeInternal(),
initializeFlagScheme(),
initializeFlags,adp-method,
initializeFlags,oce-method,
initializeFlagsInternal(),
initializeFlags(),
setFlags,adp-method,
setFlags,ctd-method,
setFlags,oce-method