inst/doc/quick_start.R

## ---- echo = FALSE, message = FALSE-------------------------------------------
knitr::opts_chunk$set(collapse = T, comment = "#>")
options(tibble.print_min = 4L, tibble.print_max = 4L)
library(prophet)
library(dplyr)

## ---- results= "hide"---------------------------------------------------------
library(readr)
df <- read_csv('../tests/testthat/data.csv')

## -----------------------------------------------------------------------------
m <- prophet(df)

## -----------------------------------------------------------------------------
future <- make_future_dataframe(m, periods = 365)
head(future)

## -----------------------------------------------------------------------------
forecast <- predict(m, future)
head(forecast)

## -----------------------------------------------------------------------------
plot(m, forecast)

## -----------------------------------------------------------------------------
prophet_plot_components(m, forecast)

Try the prophet package in your browser

Any scripts or data that you put into this service are public.

prophet documentation built on March 30, 2021, 5:05 p.m.