windkit.plot.histogram(ds, style='faceted', color='dodgerblue', weibull=None, emergent_distribution=False, gap=False, share_yaxes=True, share_xaxes=True)[source]

Plot the histogram represented in a binned wind climate.

Has the option to include the weibull distribution represented as a line over top of the histogram to qualitatively evaluate the goodness of fit.

  • ds (xarray.Dataset) – WindKit Binned wind climate at a single point, optionally with weibull parameters (A & k) if the weibull fit overlay is desired.

  • style (str or list of floats, optional) –

    Can take the following values, default is “faceted”:

    • ”faceted” : A single plot showing each sector as a separate sub-plot. The layout of the plot is designed to keep the plot “square”.

    • ”interactive” : Creates a Dash interactive plot that shows both the distribution and wind rose, hovering over different sectors in the wind rose will show the corresponding distribution plot

    • ”list” : Returns a list of plotly figures, one for each sector

  • color (str, optional) – Determines the color used for the histogram bars, default is “dodgerblue”. Strings should define valid CSS-colors.

  • weibull (bool, optional) –

    Should the weibull plot be drawn, default is None:

    • True : Add weibull using A & k from dataset if there, otherwise fit a weibull and use that for plotting

    • False : Don’t add weibull to plot

    • None : Add weibull if A & k are in dataset

  • emergent_distribution (bool, optional) –

    Should the emergent distribution be drawn, default is False:

    • True : Returns only the emergent distribution plot, ignoring the style and weibull arguments

    • False : Don’t plot the emergent distribution

  • gap (bool, optional) – Include a gap between sectors (True), default is False

  • share_yaxes (bool, optional) – Link y-axis values and labels across subplots?, default True

  • share_xaxes (bool, optional) – Link x-axis values and labels across subplots?, default True


  • plotly.graph_objects.Figure if style is “faceted” or “emergent_distribution” is True – Plotly figure for display, additional modification, or output

  • dash.dash.Dash object if style is “interactive” – Dash app (interactive plot) for display, additional modification, or output

  • List of plotly.graph_objects.Figure if style is “list” – List of Plotly figures for display, additional modification, or output