Package: rSPDE 2.5.2.9000

rSPDE: Rational Approximations of Fractional Stochastic Partial Differential Equations

Functions that compute rational approximations of fractional elliptic stochastic partial differential equations. The package also contains functions for common statistical usage of these approximations. The main references for rSPDE are Bolin, Simas and Xiong (2023) <doi:10.1080/10618600.2023.2231051> for the covariance-based method and Bolin and Kirchner (2020) <doi:10.1080/10618600.2019.1665537> for the operator-based rational approximation. These can be generated by the citation function in R.

Authors:David Bolin [cre, aut], Alexandre Simas [aut], Finn Lindgren [ctb]

rSPDE_2.5.2.9000.tar.gz
rSPDE_2.5.2.9000.zip(r-4.7)rSPDE_2.5.2.9000.zip(r-4.6)rSPDE_2.5.2.9000.zip(r-4.5)
rSPDE_2.5.2.9000.tgz(r-4.6-x86_64)rSPDE_2.5.2.9000.tgz(r-4.6-arm64)rSPDE_2.5.2.9000.tgz(r-4.5-x86_64)rSPDE_2.5.2.9000.tgz(r-4.5-arm64)
rSPDE_2.5.2.9000.tar.gz(r-4.7-arm64)rSPDE_2.5.2.9000.tar.gz(r-4.7-x86_64)rSPDE_2.5.2.9000.tar.gz(r-4.6-arm64)rSPDE_2.5.2.9000.tar.gz(r-4.6-x86_64)
rSPDE_2.5.2.9000.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
rSPDE/json (API)

# Install 'rSPDE' in R:
install.packages('rSPDE', repos = c('https://davidbolin.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/davidbolin/rspde/issues

Pkgdown/docs site:https://davidbolin.github.io

On CRAN:

Conda:

10.14 score 12 stars 5 packages 439 scripts 486 downloads 68 exports 39 dependencies

Last updated from:e06247a41e. Checks:5 WARNING, 6 ERROR, 2 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-arm64WARNING290
linux-devel-x86_64ERROR282
source / vignettesOK3088
linux-release-arm64WARNING259
linux-release-x86_64WARNING269
macos-release-arm64ERROR129
macos-release-x86_64ERROR278
macos-oldrel-arm64ERROR158
macos-oldrel-x86_64ERROR402
windows-develWARNING179
windows-releaseERROR266
windows-oldrelWARNING211
wasm-releaseOK213

Exports:augmentconstruct.spde.matern.loglikecov_function_meshcovariance_meshcreate_train_test_indicescross_validationfolded.matern.covariance.1dfolded.matern.covariance.2dfractional.operatorsget.initial.values.rSPDEgg_dfglancegraph_data_rspdeintrinsic.matern.operatorsintrinsic.operatorsmake_Amatern.covariancematern.operatorsmatern.rationalmatern.rational.covmatern2d.operatorsPl.multPl.solvePr.multPr.solveprecisionQ.multQ.solveQsqrt.multQsqrt.solverational.orderrational.order<-rational.typerational.type<-require.nowarningsrspde_lmerSPDE.A1drspde.anistropic2drSPDE.AstrSPDE.construct.matern.loglikerSPDE.fem1drSPDE.fem2drspde.intrinsicrspde.intrinsic.maternrSPDE.loglikerspde.make.Arspde.make.indexrspde.maternrSPDE.matern.loglikerspde.matern.precisionrspde.matern.precision.integerrspde.matern.precision.integer.optrspde.matern.precision.optrspde.matern1drspde.mesh.projectrspde.mesh.projectorrspde.metric_graphrspde.resultrspde.spacetimeSigma.multSigma.solvespacetime.operatorsspde.make.Aspde.matern.loglikespde.matern.operatorstransform_parameters_anisotropictransform_parameters_spacetimevariogram.intrinsic.spde

Dependencies:backportsbroomclassclassIntclicpp11DBIdplyre1071fmeshergenericsglueKernSmoothlatticelifecyclemagrittrMASSMatrixpillarpkgconfigproxypurrrR6Rcpprlangs2sfspsplancsstringistringrtibbletidyrtidyselectunitsutf8vctrswithrwk

Building the rSPDE package from source on Mac and Linux
Overview | Asking for the compiled build | Toolchain prerequisites | Linux | macOS | Inspecting and adjusting the Makefile | Windows

Last update: 2026-05-06
Started: 2023-01-18

rSPDE vs exact Matern covariance: timing and memory
Introduction | rSPDE sparse approximation | Benchmark setup | Results

Last update: 2026-01-29
Started: 2026-01-28

Spatio-temporal models
Introduction | Implementation details | Setting up a data frame | Parameter estimation | rspde_lme implementation | inlabru Implementation | A spatial example | Fit with bounded_rho = FALSE | 1D Example with bounded_rho = FALSE | References

Last update: 2026-01-25
Started: 2024-12-01

Anisotropic models
Introduction | Implementation details | Inlabru Implementation

Last update: 2026-01-25
Started: 2024-12-01

Intrinsic models in the rSPDE package
Introduction | A fractional intrinsic model | Fitting the model with R-INLA | Extreme value models | An example with replicates | A more general model | Kriging with R-INLA implementation | Using intrinsic models without R-INLA | An example with estimated alpha and beta parameters

Last update: 2026-01-25
Started: 2024-12-01

Operator-based rational approximation
Introduction | Using the package to perform operator-based rational approximations | Constructing the approximation | A non-stationary model | Using the approximation | Spatial data and parameter estimation | References

Last update: 2026-01-25
Started: 2022-01-06

Rational approximation with the rSPDE package
Introduction | Covariance-based rational SPDE approach | Constructing the approximation | Using the approximation | Fitting a model | Kriging | Fitting a model with replicates | Spatial data and parameter estimation | Further details on rspde_lme | Fixing parameters | Setting starting values | Example: Fixing and setting starting values | Using a previous fit to initialize the optimization | An example with a non-stationary model | Simulating the data | Fitting the non-stationary rSPDE model | Fixing parameters in non-stationary models | Changing the type and the order of the rational approximation | References

Last update: 2026-01-25
Started: 2022-01-06

An introduction to the rSPDE package
Introduction | A toy data set | Fitting the model with R-INLA implementation of the rational SPDE approach | Kriging with R-INLA implementation of the rational SPDE approach | Fitting the model with inlabru implementation of the rational SPDE approach | Kriging with inlabru implementation of the rational SPDE approach | Fitting the model with rSPDE | Kriging with rSPDE | References

Last update: 2025-03-21
Started: 2022-01-06

Rational approximations without finite element approximations
Introduction | Simulation | Inference | Kriging | Using the models in INLA | Using the models in inlabru | Kriging with the inlabru implementation | References

Last update: 2025-03-21
Started: 2024-12-01

inlabru implementation of the rational SPDE approach
Introduction | An example with real data | An rSPDE model for precipitation | Examining the data | Creating the rSPDE model | Mesh | Setting up the data frame | Setting up the rSPDE model | Model fitting | inlabru results | inlabru results in the original scale | Predictions | An example with replicates | Simulating the data | Fitting the inlabru rSPDE model | An example with a non-stationary model | Comparing the results by cross-validation | Further options of the inlabru implementation | References

Last update: 2024-12-01
Started: 2022-09-16

R-INLA implementation of the rational SPDE approach
Introduction | Example with real data | An rSPDE model for precipitation | Examining the data | Creating the rSPDE model | Mesh | The observation matrix | Setting up the rSPDE model | The inla.stack | Model fitting | INLA results | rSPDE-INLA results | Predictions | An example with replicates | Simulating the data | Fitting the R-INLA rSPDE model | An example with a non-stationary model | Further options of the rSPDE-INLA implementation | Changing the upper bound for the smoothness parameter | Changing the order of the rational approximation | Estimating models with fixed smoothness | Estimating models with fixed smoothness and non-integer $\alpha$ | Estimating models with fixed smoothness and integer $\alpha$ | Changing the priors | Changing the priors of $\tau$ and $\kappa$ | Changing the priors of $\rho$ (range) and $\sigma$ (std. dev.) | Changing the prior of $\nu$ | Changing the starting values | Changing the type of the rational approximation | References

Last update: 2024-12-01
Started: 2022-01-06

Readme and manuals

Help Manual

Help pageTopics
Rational approximations of fractional SPDEs.rSPDE-package rSPDE
Augment data with information from a 'rspde_lme' objectaugment augment.rspde_lme
rSPDE anisotropic inlabru mapperbru_get_mapper.inla_rspde_anisotropic2d
rSPDE inlabru mapperbru_get_mapper.inla_rspde_fintrinsic
rSPDE stationary inlabru mapperbru_get_mapper.inla_rspde_matern1d ibm_jacobian.bru_mapper_inla_rspde_matern1d ibm_n.bru_mapper_inla_rspde_matern1d ibm_values.bru_mapper_inla_rspde_matern1d
rSPDE space time inlabru mapperbru_get_mapper.inla_rspde_spacetime
rSPDE inlabru mapperbru_get_mapper.intrinsic_matern ibm_jacobian.bru_mapper_intrinsic_matern ibm_n.bru_mapper_intrinsic_matern ibm_values.bru_mapper_intrinsic_matern
Constructor of Matern loglikelihood functions for non-stationary models.construct.spde.matern.loglike
Covariance between mesh nodes and locationscov_function_mesh
Covariance between mesh nodescovariance_mesh
Create train and test splits for cross-validationcreate_train_test_indices
Perform cross-validation on a list of fitted models.cross_validation
The 1d folded Matern covariance functionfolded.matern.covariance.1d
The 2d folded Matern covariance functionfolded.matern.covariance.2d
Rational approximations of fractional operatorsfractional.operators
Initial values for log-likelihood optimization in rSPDE models with a latent stationary Gaussian Matern modelget.initial.values.rSPDE
Data frame for result objects from R-INLA fitted models to be used in ggplot2gg_df
Data frame for rspde_result objects to be used in ggplot2gg_df.rspde_result
Glance at an 'rspde_lme' objectglance glance.rspde_lme
Data extraction from metric graphs for 'rSPDE' modelsgraph_data_rspde
rSPDE inlabru mapperbru_get_mapper.inla_rspde ibm_jacobian.bru_mapper_inla_rspde ibm_jacobian.bru_mapper_inla_rspde_fintrinsic ibm_n.bru_mapper_inla_rspde ibm_n.bru_mapper_inla_rspde_fintrinsic ibm_values.bru_mapper_inla_rspde ibm_values.bru_mapper_inla_rspde_fintrinsic
Covariance-based approximations of intrinsic fieldsintrinsic.matern.operators
Covariance-based approximations of intrinsic fieldsintrinsic.operators
Projection matrix for model objectsmake_A
The Matern covariance functionmatern.covariance
Rational approximations of stationary Gaussian Matern random fieldsmatern.operators
Rational approximation of the Matern fields on intervals and metric graphsmatern.rational
Rational approximation of the Matern covariancematern.rational.cov
Rational approximations of stationary anisotropic Gaussian Matern random fieldsmatern2d.operators
Operations with the Pr and Pl operatorsoperator.operations Pl.mult Pl.solve Pr.mult Pr.solve Q.mult Q.solve Qsqrt.mult Qsqrt.solve Sigma.mult Sigma.solve
Get the precision matrix of CBrSPDEobj objectsprecision precision.CBrSPDEobj
Get the precision matrix of CBrSPDEobj2d objectsprecision.CBrSPDEobj2d
Get the precision matrix of 'inla_rspde' objectsprecision.inla_rspde
Get the precision matrix of intrinsicCBrSPDEobj objectsprecision.intrinsicCBrSPDEobj
Get the precision matrix of rSPDEobj1d objectsprecision.rSPDEobj1d
Get the precision matrix of spacetimeobj objectsprecision.spacetimeobj
Prediction of a fractional SPDE using the covariance-based rational SPDE approximationpredict.CBrSPDEobj
Prediction of an anisotropic Whittle-Matern fieldpredict.CBrSPDEobj2d
Predict method for 'inlabru' stationary Matern 1d modelspredict.inla_rspde_matern1d
Prediction of an intrinsic Whittle-Matern modelpredict.intrinsicCBrSPDEobj
Prediction of a mixed effects regression model on a metric graph.predict.rspde_lme
Prediction of a fractional SPDE using a rational SPDE approximationpredict.rSPDEobj
Prediction of a space-time SPDEpredict.spacetimeobj
Get the order of rational approximation.rational.order
Changing the order of the rational approximationrational.order<-
Get type of rational approximation.rational.type
Changing the type of the rational approximationrational.type<-
Warnings free loading of add-on packagesrequire.nowarnings
rSPDE linear mixed effects modelsrspde_lme
Observation matrix for finite element discretization on RrSPDE.A1d
Rational approximations of stationary anisotropic Gaussian Matern random fieldsrspde.anistropic2d
Observation matrix for space-time modelsrSPDE.Ast
Constructor of Matern loglikelihood functions.rSPDE.construct.matern.loglike
Finite element calculations for problems on RrSPDE.fem1d
Finite element calculations for problems in 2DrSPDE.fem2d
Rational approximations of fractional intrinsic fieldsrspde.intrinsic
Object-based log-likelihood function for latent Gaussian fractional SPDE modelrSPDE.loglike
Observation/prediction matrices for rSPDE models.rspde.make.A
rSPDE model index vector generationrspde.make.index
Matern rSPDE model object for INLArspde.matern
Intrinsic Matern rSPDE model object for INLArspde.intrinsic.matern rspde.matern.intrinsic
Object-based log-likelihood function for latent Gaussian fractional SPDE model using the rational approximationsrSPDE.matern.loglike
Precision matrix of the covariance-based rational approximation of stationary Gaussian Matern random fieldsrspde.matern.precision
Precision matrix of stationary Gaussian Matern random fields with integer covariance exponentrspde.matern.precision.integer
Optimized precision matrix of stationary Gaussian Matern random fields with integer covariance exponentrspde.matern.precision.integer.opt
Optimized precision matrix of the covariance-based rational approximationrspde.matern.precision.opt
Matern rSPDE model object for INLArspde.matern1d
Calculate a lattice projection to/from an 'inla.mesh' for rSPDE objectsrspde.mesh.project rspde.mesh.project.inla.mesh rspde.mesh.project.inla.mesh.1d rspde.mesh.project.rspde.mesh.projector rspde.mesh.projector
Matern rSPDE model object for metric graphs in INLArspde.metric_graph
rSPDE result extraction from INLA estimation resultsrspde.result
Space-Time Random Fields via SPDE Approximationrspde.spacetime
Simulation of a fractional SPDE using the covariance-based rational SPDE approximationsimulate.CBrSPDEobj
Simulation of a fractional SPDE using the covariance-based rational SPDE approximationsimulate.CBrSPDEobj2d
Simulation of a fractional intrinsic SPDE using the covariance-based rational SPDE approximationsimulate.intrinsicCBrSPDEobj
Simulation of a fractional SPDE using a rational SPDE approximationsimulate.rSPDEobj
Simulation of a Matern field using a rational SPDE approximationsimulate.rSPDEobj1d
Simulation of space-time modelssimulate.spacetimeobj
Space-time random fieldsspacetime.operators
Observation/prediction matrices for rSPDE models with integer smoothness.spde.make.A
Parameter-based log-likelihood for a latent Gaussian Matern SPDE model using a rational SPDE approximationspde.matern.loglike
Rational approximations of non-stationary Gaussian SPDE Matern random fieldsspde.matern.operators
Summarise CBrSPDE objectsprint.CBrSPDEobj print.summary.CBrSPDEobj summary.CBrSPDEobj
Summarise CBrSPDEobj2d objectsprint.CBrSPDEobj2d print.summary.CBrSPDEobj2d summary.CBrSPDEobj2d
Summary method for class "intrinsicCBrSPDEobj"print.intrinsicCBrSPDEobj print.summary.intrinsicCBrSPDEobj summary.intrinsicCBrSPDEobj
Summary Method for 'rspde_lme' Objects.summary.rspde_lme
Summary for posteriors of field parameters for an 'inla_rspde' model from a 'rspde_result' objectsummary.rspde_result
Summarise rSPDE objectsprint.rSPDEobj print.summary.rSPDEobj summary.rSPDEobj
Summarise rSPDE objects without FEMprint.rSPDEobj1d print.summary.rSPDEobj1d summary.rSPDEobj1d
Summarise spacetime objectsprint.spacetimeobj print.summary.spacetimeobj summary.spacetimeobj
Transform Anisotropic SPDE Model Parameters to Original Scaletransform_parameters_anisotropic
Transform Spacetime SPDE Model Parameters to Original Scaletransform_parameters_spacetime
Update parameters of CBrSPDEobj objectsupdate.CBrSPDEobj
Update parameters of CBrSPDEobj2d objectsupdate.CBrSPDEobj2d
Update parameters of intrinsicCBrSPDEobj objectsupdate.intrinsicCBrSPDEobj
Update parameters of rSPDEobj objectsupdate.rSPDEobj
Update parameters of rSPDEobj1d objectsupdate.rSPDEobj1d
Update parameters of spacetimeobj objectsupdate.spacetimeobj
Variogram of intrinsic SPDE modelvariogram.intrinsic.spde