obspy.core.inventory.channel.Channel.plot

Channel.plot(min_freq, output='VEL', start_stage=None, end_stage=None, label=None, axes=None, unwrap_phase=False, show=True, outfile=None)[source]

Show bode plot of the channel’s instrument response.

Parameters:
  • min_freq (float) Lowest frequency to plot.
  • output (str)

    Output units. One of:

    "DISP"
    displacement, output unit is meters
    "VEL"
    velocity, output unit is meters/second
    "ACC"
    acceleration, output unit is meters/second**2
  • start_stage (int) Sequence number of first stage that will be used (disregarding all earlier stages).
  • end_stage (int) Sequence number of last stage that will be used (disregarding all later stages).
  • label (str) Label string for legend.
  • axes (list of 2 matplotlib.axes.Axes) List/tuple of two axes instances on which to plot the amplitude/phase spectrum. If not specified, a new figure is opened.
  • unwrap_phase (bool) Set optional phase unwrapping using NumPy.
  • show (bool) Whether to show the figure after plotting or not. Can be used to do further customization of the plot before showing it.
  • outfile (str) Output file path to directly save the resulting image (e.g. "/tmp/image.png"). Overrides the show option; image will not be displayed interactively. The given path/file name is also used to automatically determine the output format. Supported file formats depend on your matplotlib backend. Most backends support png, pdf, ps, eps and svg. Defaults to None.

Basic Usage

>>> from obspy import read_inventory
>>> cha = read_inventory()[0][0][0]
>>> cha.plot(0.001, output="VEL")  

(Source code, png, hires.png)

../../_images/obspy-core-inventory-channel-Channel-plot-1.png