stLMM: Bayesian Spatial and Space-Time Linear Mixed Models

Fits Bayesian linear mixed models for spatial and space-time data with fixed effects, independent and identically distributed (iid) grouped random effects, and structured latent processes. The formula interface supports first-order autoregressive (AR(1)) effects, dense Gaussian processes, nearest-neighbor Gaussian processes, proper and Leroux conditional autoregressive (CAR) effects, ordered directed acyclic graph autoregressive (DAGAR) effects, separable CAR-time and DAGAR-time effects, and spatially varying coefficients. The sampler uses sparse precision matrix calculations when available and includes post-fitting tools for latent process recovery, fitted values, prediction, pointwise log likelihoods, and posterior sample extraction. Method details include Datta et al. (2016) <doi:10.1080/01621459.2015.1044091>, Finley et al. (2019) <doi:10.1080/10618600.2018.1537924>, Datta et al. (2019) <doi:10.1214/19-BA1177>, and May and Finley (2025) <doi:10.1016/j.spasta.2025.100917>.

Getting started

Package details

AuthorAndrew O. Finley [aut, cre], Sudipto Banerjee [ctb], Abhirup Datta [ctb], Paul B. May [ctb]
MaintainerAndrew O. Finley <finleya@msu.edu>
LicenseGPL (>= 3)
Version0.0.5
URL https://github.com/finleya/stLMM  https://finleya.github.io/stLMM/ 
Package repositoryView on CRAN
Installation Install the latest version of this package by entering the following in R:
install.packages("stLMM")

Try the stLMM package in your browser

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

stLMM documentation built on Nov. 12, 2026, 1:07 a.m.