ocean_model_skill_assessor.plot.surface#

Surface plot.

Functions

plot(obs, model, xname, yname, zname, suptitle)

Plot scatter or surface plot.

ocean_model_skill_assessor.plot.surface.plot(obs, model, xname, yname, zname, suptitle, xlabel=None, ylabel=None, zlabel=None, model_title='Model', along_transect_distance=False, plot_on_map=False, proj=None, extent=None, kind='pcolormesh', nsubplots=3, figname='figure.png', dpi=100, figsize=(15, 6), return_plot=False, invert_yaxis=False, make_Z_negative=None, **kwargs)[source]#

Plot scatter or surface plot.

For featuretype of trajectoryProfile or timeSeriesProfile.

Parameters:
  • obs (DataFrame, Dataset) – Observation time series

  • mode (Dataset) – Model time series to compare against obs

  • xname (str) – Name of variable to plot on x-axis when interpreted with cf-xarray and cf-pandas

  • yname (str) – Name of variable to plot on y-axis when interpreted with cf-xarray and cf-pandas

  • zname (str) – Name of variable to plot with color when interpreted with cf-xarray and cf-pandas

  • suptitle (str, optional) – Title for plot, over all the subplots.

  • xlabel (str, optional) – Label for x-axis.

  • ylabel (str, optional) – Label for y-axis.

  • zlabel (str, optional) – Label for colorbar.

  • along_transect_distance – Set to True to calculate the along-transect distance in km from the longitude and latitude, which must be interpretable through cf-pandas or cf-xarray as “longitude” and “latitude”.

  • kind (str) – Can be “pcolormesh” for surface plot or “scatter” for scatter plot.

  • nsubplots (int, optional) – Number of subplots. Might always be 3, and that is the default.

  • figname (str) – Filename for figure (as absolute or relative path).

  • dpi (int, optional) – dpi for figure. Default is 100.

  • figsize (tuple, optional) – Figsize to pass to plt.figure(). Default is (15,5).

  • return_plot (bool) – If True, return plot. Use for testing.