The Ocean Navigator is an online tool that is used to help visualise scientific research data. a users guide is available at https://dfo-ocean-navigator.github.io/Ocean-Navigator-Manual/ and the tool is live at
Received a request to add a Water Density variable to the Navigator (see Issue #1147). A density function has already been implemented in data/calculated_parser/functions.py but the pressure values needed to be padded so that they could be broadcast against salinity and temperature to calculate the sea water density. For this I used the same approach as other calculated variables such as sound speed.
Why did you take this approach?
Same approach has been used in other calculated variable functions and has been shown to work.
Screenshot(s)
Checks
[X] I ran unit tests.
[X] I've tested the relevant changes from a user POV.
Background
Received a request to add a Water Density variable to the Navigator (see Issue #1147). A density function has already been implemented in
data/calculated_parser/functions.py
but the pressure values needed to be padded so that they could be broadcast against salinity and temperature to calculate the sea water density. For this I used the same approach as other calculated variables such as sound speed.Why did you take this approach?
Same approach has been used in other calculated variable functions and has been shown to work.
Screenshot(s)
Checks
black .
.