gridfile.edit

Rewrite gridfile metadata


Syntax



Description

obj.edit(dimension, metadata)

Replace the metadata for the named dimension with new values. The new metadata must have the same number of rows as the previous metadata.

obj.edit(‘attributes’, attributes)

Replace the existing metadata attributes with new values.


Input Arguments

dimension

string scalar
The name of a dimension in the .grid file.

metadata

matrix, numeric | logical | char | string | cellstring | datetime
New metadata for the dimension. The number of rows must match the length of the dimension. Cannot have NaN or NaT elements.

attributes

scalar struct
New non-dimensional metadata attributes. May contain any fields or contents.