fpca_bayes() for Bayesian Functional Principal Component Analysis,
modelling a functional outcome as μ(t) plus a low-rank FPC expansion with
posterior inference on the mean function, FPC scores, eigenvalue standard
deviations, and the residual SD. Initial eigenfunctions are obtained from
refund::fpca.sc() and held fixed during sampling.joint_FPCA argument to sofr_bayes(), fcox_bayes(), and
fofr_bayes() for jointly modelling each functional predictor via FPCA
alongside the regression coefficients. When enabled, the predictor is
replaced by an FPCA representation and FPC scores are sampled jointly
with β(·), propagating measurement-error uncertainty into the posterior
of the regression coefficient (errors-in-variables-aware fit).fpca_bayes() and the Joint-FPCA option.README.md with inline comments
explaining the formula syntax and sampler arguments.\VignetteIndexEntry to silence
rmarkdown::html_vignette title-mismatch warnings.brms and dplyr from Imports. The two brms::brmsformula()
call-sites were replaced with stats::as.formula(), and the .data
pronoun used in ggplot calls is already re-exported by ggplot2. This
trims the install dependency tree noticeably (brms transitively pulled
in posterior, bridgesampling, loo, bayesplot, etc.).fofr_bayes() for Bayesian Function-on-Function Regression (FoFR),
supporting functional responses with functional and scalar predictors. The
bivariate coefficient surface β(s, t) is represented via a tensor-product
basis with dual-direction smoothness (random-effect reparameterisation in
the predictor direction and a penalty-matrix prior in the response
direction).README.md: added a supported-models table, links to per-function
vignettes, a citation to Jiang et al. (2025, Statistics in Medicine),
and CRAN status / downloads badges.fcox_bayes() examples so that pkgdown can parse and
render the reference page.Simulation/StanFoFR_Gaussian.stan) and
a formal simulation script (Simulation/FoFR_Simulation.R) for
reproducible FoFR benchmarking without recompiling Stan code via
refundBayes at every run.Initial public release of refundBayes, a package providing a convenient
interface for Bayesian functional regression using Stan. The package is
designed to mirror the mgcv::gam formula syntax familiar to users of
refund, while delivering full
Bayesian posterior inference via rstan.
sofr_bayes() — Bayesian Scalar-on-Function Regression, supporting
Gaussian, binomial, and Poisson families, with one or more functional
predictors alongside scalar covariates.fosr_bayes() — Bayesian Function-on-Scalar Regression with FPCA-based
residual structure for modelling subject-level functional deviations.fcox_bayes() — Bayesian Functional Cox Regression for time-to-event
outcomes with functional and scalar predictors, including posterior
inference on the log-hazard ratio surface.mgcv::smoothCon(), with spectral reparameterisation
(mgcv::smooth2random()) into fixed and random effect components.bs argument in the formula interface.summary() and plot() methods for posterior summaries and
visualisation of functional coefficients with credible bands.example_data_sofr, example_data_FoSR,
example_data_Cox) shipped with the package.