Plot recipes

Plot recipes are enabled by importing Plots:

using Plots

We provide a plot recipe to display signals:

plot(data::SampledSignal; t0=0.0, downsample=:auto, pooling=:auto, kwargs...)

Optional arguments:

  • t0=0.0: start time (for labeling only)
  • downsample=:auto: downsampling factor (integer or :auto)
  • pooling=:auto: pooling mode (:auto, :min, :max, :mean, :minmax, nothing or function)

If the signal is too long, it is automatically downsampled in a perceptually meaningful way. The downsampling can be controlled using the downsample and pooling keywords.

We also provide convenience plot recipes for common signal processing plots:

SignalAnalysis.psdFunction
psd(data; kwargs...)

Plots the power spectral density of data.

Optional keyword arguments

  • fs=1.0: derived from the data if a SampledSignal is provided as input
  • nfft=512: size of FFT window
  • noverlap=nfft÷2: window overlap size
  • window=hamming(nfft): accepts any window from DSP.jl
  • xscale=:auto: one of :auto, :identity or :log10
  • yrange=50: y-scale dB range for automatic scaling
  • other kwargs are passed on to plot
source
SignalAnalysis.specgramFunction
specgram(data; kwargs...)

Plots a spectrogram of the data.

Optional keyword arguments

  • fs=1.0: derived from the data if a SampledSignal is provided as input
  • nfft=256: size of FFT window
  • noverlap=nfft÷2: window overlap size
  • window=hamming(nfft): accepts any window from DSP.jl
  • t0=0.0: start time
  • downsample=:auto: downsampling factor (integer) for time axis
  • pooling=:mean: pooling mode (:min, :max, :mean, nothing or function)
  • crange=50: color scale dB range for automatic scaling
  • other kwargs are passed on to plot
source
Missing docstring.

Missing docstring for freqresp. Check Documenter's build log for details.