Skip to content

This code processes oceanographic temperature and depth data, calculates salinity and geostrophic velocity, and saves the results in a NetCDF file.

Notifications You must be signed in to change notification settings

xbt-community/PosProAX97---Complete

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 

Repository files navigation

PosProAX97

This code processes oceanographic temperature and depth data, calculates salinity and geostrophic velocity, and saves the results in a NetCDF file.

This code performs a full processing of oceanographic data, from initial reading to the creation of a final NetCDF file, which contains several calculated variables.

Data Loading and Preparation: The script starts by reading temperature and depth data files from multiple cruises. It handles potential inconsistencies, such as missing data (represented by 0) and differences in array sizes, to ensure the data is clean and uniform.

Interpolation and Smoothing: To ensure all data is on a consistent grid, the code interpolates the temperature onto a fixed reference grid (defined by longitude and depth). It then applies a 2D smoothing filter (using a LOESS method) to remove noise and make the data more consistent. A bathymetry mask is applied to discard data points located below the seabed.

Calculation of Oceanographic Variables: Using the gsw and MOVARTEAM libraries, the script calculates salinity, conservative temperature (CT), absolute salinity (SA), and geopotential anomaly. Salinity is derived from temperature and depth, and the geopotential anomaly is adjusted using Argo climatology data to obtain a more accurate total dynamic height.

Geostrophic Velocity and Transport Calculation: From the total dynamic height, the script calculates the geostrophic velocity perpendicular to the section. Based on this velocity, it computes the geostrophic volume transport, both for southward flow (using only negative velocities) and for net transport (the balance between southward and northward flows).

Visualization and Statistics: For each processed file, the code generates plots of dynamic height and a contour map of the geostrophic velocity. It also calculates key statistics, such as maximum and minimum values, means, and standard deviations for the main variables and the calculated transports.

Creating the Output File: Finally, all the processed and calculated variables (SA, CT, dynamic height, geostrophic velocity, and transports) are stacked and saved into a single NetCDF file. The file includes detailed metadata attributes, making the data organized, standardized, and ready for future analysis.

About

This code processes oceanographic temperature and depth data, calculates salinity and geostrophic velocity, and saves the results in a NetCDF file.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages