NDBC Buoy Data Request (of any type)

The NDBC keeps a 40-day recent rolling file for each buoy. This examples shows how to access the other types of data available for a buoy.

from siphon.simplewebservice.ndbc import NDBC

Request the types of data available from a given buoy.

{'txt': 'standard meteorological data', 'spec': 'spectral wave summaries', 'data_spec': 'raw spectral wave data', 'swdir': 'spectral wave data (alpha1)', 'swdir2': 'spectral wave data (alpha2)', 'swr1': 'spectral wave data (r1)', 'swr2': 'spectral wave data (r2)', 'supl': 'supplemental measurements data'}

Get a pandas data frame of all of the observations, meteorological data is the default observation set to query.

df = NDBC.realtime_observations('42012', data_type='supl')
df.head()
/opt/hostedtoolcache/Python/3.14.3/x64/lib/python3.14/site-packages/pandas/core/arrays/timedeltas.py:1163: RuntimeWarning: invalid value encountered in cast
  int_data = data.astype(np.int64)
/opt/hostedtoolcache/Python/3.14.3/x64/lib/python3.14/site-packages/pandas/core/arrays/timedeltas.py:1163: RuntimeWarning: invalid value encountered in cast
  int_data = data.astype(np.int64)
hourly_low_pressure hourly_low_pressure_time hourly_high_wind hourly_high_wind_direction hourly_high_wind_time time
0 1027.6 2026-03-18 17:09:00+00:00 6.0 50.0 2026-03-18 17:04:00+00:00 2026-03-18 17:10:00+00:00
1 1027.6 2026-03-18 17:00:00+00:00 6.0 50.0 2026-03-18 16:56:00+00:00 2026-03-18 17:00:00+00:00
2 1027.6 2026-03-18 16:41:00+00:00 6.0 60.0 2026-03-18 16:46:00+00:00 2026-03-18 16:50:00+00:00
3 1027.6 2026-03-18 16:31:00+00:00 6.0 80.0 2026-03-18 16:36:00+00:00 2026-03-18 16:40:00+00:00
4 1027.6 2026-03-18 16:22:00+00:00 7.0 60.0 2026-03-18 16:22:00+00:00 2026-03-18 16:30:00+00:00


Total running time of the script: (0 minutes 2.584 seconds)

Gallery generated by Sphinx-Gallery