simplify_units

function of dascore.proc.units source

simplify_units(
    patch: Patch ,
)-> ‘PatchType’

Simplify the units contained by the patch to base metric units.

All data and coordinate units will be converted to their base units and corresponding data/labels multiplied by a conversion factor.

Examples

import dascore as dc
patch = dc.get_example_patch()

# Set complex units
complex_units = patch.set_units("km/h", distance="km", time="h")

# Simplify to base units (m/s, m, s)
simplified = complex_units.simplify_units()