mirror of
https://github.com/saymrwulf/prophet.git
synced 2026-05-24 22:17:39 +00:00
* added `flat_growth_init()` function * added validation for 'flat' * changed `fit.prophet()` to handle `growth='flat'` * added `trend='flat'` capabilities to `sample_predictive_trend()` and `fit.prophet()` * updated STAN code to handle flat trend * [Syntax fix] Removed unnecessary bracket * updated documentation * undid formatting that was accidentally applied by autoformatter * undid more formatting that was accidentally applied by autoformatter * added tests * typo in `sample_predictive_trend()` * updated notebook with example in R * updated documentation
22 lines
624 B
R
22 lines
624 B
R
% Generated by roxygen2: do not edit by hand
|
|
% Please edit documentation in R/prophet.R
|
|
\name{linear_growth_init}
|
|
\alias{linear_growth_init}
|
|
\title{Initialize constant growth.}
|
|
\usage{
|
|
linear_growth_init(df)
|
|
}
|
|
\arguments{
|
|
\item{df}{Data frame with columns ds (date), y_scaled (scaled time series),
|
|
and t (scaled time).}
|
|
}
|
|
\value{
|
|
A vector (k, m) with the rate (k) and offset (m) of the linear
|
|
growth function.
|
|
}
|
|
\description{
|
|
Provides a strong initialization for linear growth by calculating the
|
|
growth and offset parameters that pass the function through the first and
|
|
last points in the time series.
|
|
}
|
|
\keyword{internal}
|