-
Notifications
You must be signed in to change notification settings - Fork 0
das2c_props
C. Piker edited this page Dec 7, 2023
·
2 revisions
das2c_props
Get dataset metadata properties
property_array = das2c_props(struct)
property = das2c_props(struct, key)
Parameter | Type | Purpose |
---|---|---|
struct | DAS2C_DSET DAS2C_PDIM |
Properties can be attached to datasets as a whole or to variable groups. The structure type is inspected to determine which properties are desired |
Parameter | Type | Purpose |
---|---|---|
key | String | All properties have a name. Get a specific property instead of a array of all properties for the structure |
This function returns an array of DAS2C_PROP structures providing the property or properties of the dataset. DAS2C_PROP structures have the following fields.
Field | Type | Purpose |
---|---|---|
KEY | String | The name of the property |
TYPE | String | The intended final data type for the property, will be one of
|
VALUE | String | A string version of the property value |
If a prop key is given as an input but the dataset has no properties with
that name, !NULL
is returned. If the dataset has no properties at all,
then !NULL is returned when the the full property list is requested.
- Get all the properties for dataset 1 from query result ID 48.
result = das2c_results(48) ds = das2c_datasets(result, 1) das2c_dsprops(ds)
- Get the 'label' property for the time dimension from the dataset above.
pd_time = das2c_pdims(ds, 'time') das2c_dsprops(pd_time, 'label')
C. Piker, 2020-03-13 - Initial Version