Tools to load hydrographic data into pandas DataFrame
Python
Switch branches/tags
Nothing to show
Clone or download
Pull request Compare This branch is 5 commits behind pyoceans:master.
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
conda.recipe
ctd
docs
tests
.stickler.yml
.travis.yml
CHANGES.txt
LICENSE.txt
MANIFEST.in
README.rst
appveyor.yml
requirements-dev.txt
requirements.txt
setup.py

README.rst

python-ctd

DOI Version_status travis appveyor license

Tools to load hydrographic data as pandas DataFrame with some handy methods for data pre-processing and analysis

This module can load SeaBird CTD (CNV), Sippican XBT (EDF), and Falmouth CTD (ASCII) formats.

Quick intro

pip install ctd

and then,

from ctd import DataFrame

kw = dict(compression='gzip')
fname = './test/data/CTD/g01l06s01.cnv.gz'
cast = DataFrame.from_cnv(fname, **kw)
downcast, upcast = cast.split()
fig, ax = downcast['t090C'].plot()

Bad Processing

We can do better:

from ctd import DataFrame, lp_filter, movingaverage

kw.update(below_water=True)
cast = DataFrame.from_cnv(fname, **kw)
downcast, upcast = cast.split()
temperature = downcast['t090C'].despike(n1=2, n2=20, block=100)
temperature.index = lp_filter(temperature.index.values)
temperature = temperature.bindata(delta=1)
temperature = temperature.interpolate()
temperature = temperature.smooth(window_len=21, window='hanning')
fig, ax = temperature.plot()
ax.axis([0, 30, 2000, 0])
ax.set_ylabel("Pressure [dbar]")
ax.set_xlabel(u'Temperature [\u00b0C]')

Good Processing

Not so quick intro

Profiles and sections.

Author

Filipe Fernandes