Documentation fixes

This commit is contained in:
Ben Letham 2018-12-03 13:25:26 -08:00
parent 536fe931c6
commit e3ad97b8b3
6 changed files with 13 additions and 6 deletions

View file

@ -9,9 +9,7 @@ export(add_seasonality)
export(cross_validation)
export(dyplot.prophet)
export(fit.prophet)
export(get_holiday_names)
export(make_future_dataframe)
export(make_holidays_df)
export(performance_metrics)
export(plot_cross_validation_metric)
export(plot_forecast_component)

View file

@ -11,7 +11,7 @@
#' @param country.name Country name (character).
#'
#' @return A vector of all possible holiday names (unique) of given country.
#' @export
#' @internal
get_holiday_names <- function(country.name){
holidays <- generated_holidays %>%
dplyr::filter(country == country.name) %>%
@ -23,11 +23,12 @@ get_holiday_names <- function(country.name){
#' Make dataframe of holidays for given years and countries
#'
#' @param years List of years for which to include holiday dates.
#' @param country.name Country name (character).
#'
#' @return Dataframe with 'ds' and 'holiday', which can directly feed
#' to 'holidays' params in Prophet
#' @export
#' @internal
make_holidays_df <- function(years, country.name){
country.holidays = generated_holidays %>%
dplyr::filter(country == country.name)

View file

@ -8,10 +8,12 @@
## Makes R CMD CHECK happy due to dplyr syntax below
globalVariables(c(
"ds", "y", "cap", ".",
"component", "dow", "doy", "holiday", "holidays", "holidays_lower",
"component", "dow", "doy", "holiday", "holidays", "holidays_lower", "generated_holidays",
"holidays_upper", "ix", "lower", "n", "stat", "trend", "row_number", "extra_regressors", "col",
"trend_lower", "trend_upper", "upper", "value", "weekly", "weekly_lower", "weekly_upper",
"x", "yearly", "yearly_lower", "yearly_upper", "yhat", "yhat_lower", "yhat_upper"))
"x", "yearly", "yearly_lower", "yearly_upper", "yhat", "yhat_lower", "yhat_upper",
"country", "year"
))
#' Prophet forecaster.
#'

View file

@ -7,6 +7,8 @@
make_holidays_df(years, country.name)
}
\arguments{
\item{years}{List of years for which to include holiday dates.}
\item{country.name}{Country name (character).}
}
\value{

View file

@ -9,6 +9,9 @@ validate_inputs(m)
\arguments{
\item{m}{Prophet object.}
}
\value{
The Prophet object.
}
\description{
Validates the inputs to Prophet.
}

View file

@ -435,6 +435,7 @@ def plot_cross_validation_metric(
In [0, 1]. Defaults to 0.1.
ax: Optional matplotlib axis on which to plot. If not given, a new figure
will be created.
figsize: Optional tuple width, height in inches.
Returns
-------