View source: R/stan_p_spline.R
stan_p_spline | R Documentation |
Bayesian p-spline model using stan
stan_p_spline(
X,
Y,
N,
target_dist_between_knots = 5,
spline_degree = 3,
iter = 20000,
warmup = 1000,
cores = 1,
chains = 4
)
X |
date vector. |
Y |
Numeric vector of number of positive samples |
N |
Numeric vector of total number of samples |
spline_degree |
sets the degree of the splines (default = 3) |
target_distance_between_knots |
sets the number of days between adjacent knots (default = 5) |
... |
Arguments passed to |
An object of class stanfit
returned by rstan::sampling
Convert date to numeric Load and run stan model
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.