paul-buerkner/brms

Add support for a continuous time AR(1) analogue to cor_ar()

Open

#741 aberto em 29 de ago. de 2019

Ver no GitHub
 (8 comments) (5 reactions) (0 assignees)R (220 forks)batch import
autocorrelationfeaturegood first issue

Métricas do repositório

Stars
 (1.402 stars)
Métricas de merge de PR
 (Mesclagem média 7d 21h) (1 fundiu PR em 30d)

Description

The discrete time AR(1) correlation structure can be generalised to the continuous time setting.

A continuous time AR(1) or CAR(1) correlation structure can be defined as

h(s, ϕ) = ϕs, s ≥ 0, ϕ ≥ 0

where s is a non-negative real. In contrast to the AR(1), the correlation parameter ϕ is constrained to be non-negative. The CAR(1) correlation function is a univariate special case of the exponential spatial correlation function.

The nlme package has an implementation of this correlation function in its nlme::corCAR1().

A cor_car1() function in brms mirroring cor_ar() but for the CAR(1) correlation would be very useful for modelling longitudinal data for example in settings where the observations are not regularly spaced in time.

There is a small amount of discussion of this on the Stan Discourse site.

Guia do colaborador