MCPcopy
hub / github.com/facebook/prophet / plot_components

Method plot_components

python/prophet/forecaster.py:1913–1942  ·  view source on GitHub ↗

Plot the Prophet forecast components. Will plot whichever are available of: trend, holidays, weekly seasonality, and yearly seasonality. Parameters ---------- fcst: pd.DataFrame output of self.predict. uncertainty: Optional boolean to plot uncertaint

(self, fcst, uncertainty=True, plot_cap=True,
                        weekly_start=0, yearly_start=0, figsize=None)

Source from the content-addressed store, hash-verified

1911 )
1912
1913 def plot_components(self, fcst, uncertainty=True, plot_cap=True,
1914 weekly_start=0, yearly_start=0, figsize=None):
1915 """Plot the Prophet forecast components.
1916
1917 Will plot whichever are available of: trend, holidays, weekly
1918 seasonality, and yearly seasonality.
1919
1920 Parameters
1921 ----------
1922 fcst: pd.DataFrame output of self.predict.
1923 uncertainty: Optional boolean to plot uncertainty intervals.
1924 plot_cap: Optional boolean indicating if the capacity should be shown
1925 in the figure, if available.
1926 weekly_start: Optional int specifying the start day of the weekly
1927 seasonality plot. 0 (default) starts the week on Sunday. 1 shifts
1928 by 1 day to Monday, and so on.
1929 yearly_start: Optional int specifying the start day of the yearly
1930 seasonality plot. 0 (default) starts the year on Jan 1. 1 shifts
1931 by 1 day to Jan 2, and so on.
1932 figsize: Optional tuple width, height in inches.
1933
1934 Returns
1935 -------
1936 A matplotlib figure.
1937 """
1938 return plot_components(
1939 m=self, fcst=fcst, uncertainty=uncertainty, plot_cap=plot_cap,
1940 weekly_start=weekly_start, yearly_start=yearly_start,
1941 figsize=figsize
1942 )

Callers

nothing calls this directly

Calls 1

plot_componentsFunction · 0.90

Tested by

no test coverage detected