Decorator to append data to surface.

Parameters:to ({'point', 'cell', 'field'}, optional) – Append data to PointData, CellData or FieldData. Default is ‘point’.
Returns:wrapped_func (callable) – Wrapped function.


All functions using this decorator must:

  • Return an ndarray. The size of the array must be consistent with the data it will be appended to (e.g., number of points if to == 'point'), except for FieldData.
  • Have the following 2 key-value arguments:
    1. append (bool, optional)
      If True, append data to surface. Otherwise, return data.
    2. key (str, optional)
      Array names of data.