# obspy.signal.tf_misfit.plot_tfr

`plot_tfr`(st, dt=0.01, t0=0.0, fmin=1.0, fmax=10.0, nf=100, w0=6, left=0.1, bottom=0.1, h_1=0.2, h_2=0.6, w_1=0.2, w_2=0.6, w_cb=0.01, d_cb=0.0, show=True, plot_args=['k', 'k'], clim=0.0, cmap=<matplotlib.colors.LinearSegmentedColormap object at 0x4310a34c>, mode='absolute', fft_zero_pad_fac=0)

  Plot time frequency representation, spectrum and time series of the signal.

  Parameters: | st signal, type numpy.ndarray with shape (number of components, number of time samples) or (number of timesamples, ) for single component data dt time step between two samples in st t0 starting time for plotting fmin minimal frequency to be analyzed fmax maximal frequency to be analyzed nf number of frequencies (will be chosen with logarithmic spacing) w0 parameter for the wavelet, tradeoff between time and frequency resolution left plot distance from the left of the figure bottom plot distance from the bottom of the figure h_1 height of the signal axis h_2 height of the TFR/spectrum axis w_1 width of the spectrum axis w_2 width of the TFR/signal axes w_cb width of the colorbar axes d_cb distance of the colorbar axes to the other axes show show figure or return plot_args list of plot arguments passed to the signal and spectrum plots clim limits of the colorbars cmap colormap for TFEM/TFPM, either a string or matplotlib.cm.Colormap instance mode ‘absolute’ for absolute value of TFR, ‘power’ for `|TFR|^2` fft_zero_pad_fac integer, if > 0, the signal is zero padded to `nfft = next_pow_2(len(st)) * fft_zero_pad_fac` to get smoother spectrum in the low frequencies (has no effect on the TFR and might make demeaning/tapering necessary to avoid artifacts)
  Returns: | If show is False, returns a matplotlib.pyplot.figure object (single component data) or a list of figure objects (multi component data)

  Example

      >>> from obspy import read
      >>> tr = read("https://examples.obspy.org/a02i.2008.240.mseed")[0]
      >>> plot_tfr(tr.data, dt=tr.stats.delta, fmin=.01,
      ...         fmax=50., w0=8., nf=64, fft_zero_pad_fac=4)

  (Source code, png, hires.png)

### Thank you!

We would like to thank our contributors, whose efforts make this software what it is. These people have helped by writing code and documentation, and by testing. They have created and maintained this product, its associated libraries and applications, our build tools and our web sites.

#### Contributors

- Ackerley, Nick
- Allgeyer, Sebastien
- Ammon, Charles J.
- Antunes, Emanuel
- Arnarsson, Ólafur St.
- Bank, Markus
- Barsch, Robert
- Behr, Yannik
- Bernardi, Fabrizio
- Bernauer, Felix
- Bes de Berc, Maxime
- Beyreuther, Moritz
- Boltz, Shawn
- Bonaimé, Sébastien
- Carothers, Lloyd
- Chamberlain, Calum
- Chambers, Derrick
- Chen, Zhao
- Clark, Adam
- Danecek, Peter
- Egdorf, Sven
- Engels, Fabian
- Ermert, Laura
- Eulenfeld, Tom

- Fabbri, Tommaso
- Falco, Nicholas
- Fee, Jeremy
- Grellier, Clément
- Grunberg, Marc
- Hammer, Conny
- Heimann, Sebastian
- Heiniger, Lukas
- Hope, Gaute
- Igel, Heiner
- Inza, Adolfo
- Isken, Marius
- Ketchum, David
- Koymans, Mathijs
- Kremers, Simon
- Kress, Victor
- Krieger, Lars
- Krischer, Lion
- Kula, Damian
- Käufl, Paul
- Köhler, Andreas
- Lecocq, Thomas
- Leeman, John
- Legovini, Paride

- Lesage, Philippe
- Li, Yulin
- Lomax, Anthony
- Lopes, Rui L.
- MacCarthy, Jonathan
- Maggi, Alessia
- Martin, Henri
- Medlin, Andrew
- Megies, Tobias
- Meschede, Matthias
- Michelini, Alberto
- Miller, Nathaniel C.
- Morgenstern, Bernhard
- Nof, Ran Novitsky
- Panning, Mark P.
- Parker, Tom
- Pestourie, Romain
- Rapagnani, Giovanni
- Reyes, Celso
- Ringler, Adam
- Rothenhäusler, Nicolas
- Russo, Emiliano
- Sales de Andrade, Elliott

- Satriano, Claudio
- Saul, Joachim
- Scheingraber, Chris
- Schneider, Simon
- Sippl, Christian
- Snoke, Arthur
- Stange, Stefan
- Stähler, Simon C.
- Sullivan, Benjamin
- Tian, Dongdong
- Trabant, Chad
- Trani, Luca
- Uieda, Leonardo
- Walker, Andrew
- Walther, Marcus
- Wassermann, Joachim
- Williams, Mark C.
- Winkelman, Andrew
- Zaccarelli, Riccardo
- Zad, Seyed Kasra Hosseini
- Zhu, Lijun
- van Driel, Martin
- van Wijk, Kasper

#### Funds

ObsPy was partially funded by the

- German Science Foundation (DFG) via grant DFG IG 16/9-1
- German Ministry for Education and Research (BMBF), GEOTECHNOLOGIEN grant 03G0646H.
- NERA project (Network of European Research Infrastructures for Earthquake Risk Assessment and Mitigation) under the European Community's Seventh Framework Programme (FP7/2007-2013) grant agreement n° 262330
- Leibniz Institute for Applied Geophysics (LIAG)
- VERCE EU-FP7 project (no. 283543)