ACHMartin/seastar_project

What outputs for each function: Full DataSet with the additional fields or the computed DataArray

Closed this issue · 4 comments

We tend to do return the full DataSet with the additional field.
Should we return the DataArray instead. I think it believe of the cases, perhaps we can discuss here the cases where DataArray output should be prefer.
The new API would be:
dsl2['newField'] = compute_new_field(dsl2)
instead of the current:
dsl2 = compute_new_field(dsl2)

I would go for the DataArray output for:
compute_radial_surface_current
potentially for
compute_current_magnitude_and_direction

I've had similar thoughts, and it wouldn't be too much effort to change. It'll be more transparent in a lot of cases I think

Perhaps start with functions that only return one or two output arrays (e.g., U, V)

Closed with #224