NPIOcean / kval

Tools for analysis and processing of ocean data in Python.
MIT License
2 stars 0 forks source link

Behaviour when running ctd.inspect_dual_sensors() with no dual sensors #16

Closed oyvfoss closed 3 months ago

oyvfoss commented 3 months ago

data.ctd.inspect_dual_sensors(ds) currently returns an error ("IndexError: list index out of range") if there are no dual sensors.

The function is a wrapper for data.ctd._ctd_visualize.inspect_dual_sensors, so thats where we have to apply a fix.

Should do a check for dual sensors and do something like return a string "No dual sensors in dataset" if variable_pairs is empty.

oyvfoss commented 3 months ago

Done (0a93f95f548f8444087a6a9d88f6a284daabd693)