Skip to main content

Tools to load hydrographic data into pandas DataFrame

Project description

python-ctd

DOI Build Status PyPI Build status 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

conda install ctd --channel conda-forge
pip install ctd

and then,

from pathlib import Path
import ctd

path = Path('tests', 'data', 'CTD')
fname = path.joinpath('g01l06s01.cnv.gz')

down, up = ctd.from_cnv(fname).split()
ax = down['t090C'].plot_cast()

Bad Processing

We can do better:

temperature = down['t090C']

fig, ax = plt.subplots(figsize=(5.5, 6))
temperature.plot_cast(ax=ax)
temperature.remove_above_water()\
           .despike()\
           .lp_filter()\
           .press_check()\
           .interpolate(method='index',
                        limit_direction='both',
                        limit_area='inside')\
           .bindata(delta=1, method='interpolate')\
           .smooth(window_len=21, window='hanning') \
           .plot_cast(ax=ax)
ax.set_ylabel('Pressure (dbar)')
ax.set_xlabel('Temperature (°C)')

Good Processing

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ctd-1.4.0.tar.gz (76.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ctd-1.4.0-py3-none-any.whl (15.7 kB view details)

Uploaded Python 3

File details

Details for the file ctd-1.4.0.tar.gz.

File metadata

  • Download URL: ctd-1.4.0.tar.gz
  • Upload date:
  • Size: 76.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for ctd-1.4.0.tar.gz
Algorithm Hash digest
SHA256 e34e02320c3be571705098406dbbf47064f233d0f4806710208bb90d47006b4d
MD5 e8f1079a937044b7c35a5a74951e364d
BLAKE2b-256 dfd862b7c79d749b91c6428de52467fad2921236dd32d851e0543d9133ebbf7e

See more details on using hashes here.

File details

Details for the file ctd-1.4.0-py3-none-any.whl.

File metadata

  • Download URL: ctd-1.4.0-py3-none-any.whl
  • Upload date:
  • Size: 15.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.13

File hashes

Hashes for ctd-1.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 acf73e9885eb9fa0e23556e3b27cc0810f1339d5528be86c48dd553426bfb048
MD5 acb966ee4ef23a89215920bc9e53f88d
BLAKE2b-256 d661278620260d8112e5d2561dda3cc7566a1868ebfadf80bca679db32156a33

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page