2.10.3. vacumm.tide.marigraph
– Traitements marégraphiques¶
Provides a class to perform basic operations on marigraphic sea level data
-
class
Marigraph
(data, tide_filter='demerliac', outside_std=3.5, bad_values=None, verbose=False, mean=None, **kwargs)[source]¶ Bases:
object
A marigraph class that support statistics and plots.
You give as input a 1D cdms sea level variable with a suitable time, or a tide.StationInfo() object, or simply a 5-letter shom ID. The class will design an object with high and low tides, and pure tidal and without tidal signal. You can optionnally specify a time axis on wich the input signal is to be interpolated before any processing. You can also restrict the time range and perfom a running average.
Parameters: All parameters are passed to
set()
data : It can be either
- A
cdms2
1D array with a time axis. - A
StationInfo
instance. - The name of a station that can be search for using
StationInfo
.
- A
select: time range for data selection (like (‘1999’,‘2000-01-01’,’co’)). If None, time range is reset [default: None],
global_anomaly: First remove the anomaly of the whole signal before any processing [default: False]
anomaly: Remove the anomaly of the restricted sample before any processing [default: False]
shom_anomaly: Same but removed mean is get from observation at correspondind shom station [default: False]
%s
Example: >>> # Get data >>> from vacumm.tide import Marigraph >>> brest = Marigraph('BREST',range=('2006-03','2006-08'),hourly=True) >>> # Plot >>> brest.plot_sea_level() >>> brest.plot_low_high() >>> brest.plot_cotes() >>> # Change time range >>> brest.set_time_range(('2006-07','2006-08','co')) >>> # Change tide filter >>> brest.set_tide_filter('godin') >>> # Save >>> f = cdms.open('mytide.nc') >>> f.write(brest.cotes()) >>> f.write(brest.high()) >>> f.write(brest.low()) >>> f.write(brest.zeros()) >>> f.close()
-
cotes
(anom=True, **kwargs)[source]¶ Return the sea level without the tide signal (surcotes and decotes). You must specify the filter before using this method.
%(ref)s
-
plot
(var=None, orig=True, tide=True, cotes=True, highs=True, lows=True, zeros=True, legend=True, title=None, savefig=None, savefigs=None, show=True, marker='o', **kwargs)[source]¶