markov_two_states: Markov two-state missingness model ('missingness_model')

View source: R/time_series_model.R

markov_two_statesR Documentation

Markov two-state missingness model (missingness_model)

Description

Constructs a missingness_model representing a two-state Markov process for missing/observed indicators. The process takes values in {0, 1}, where 1 indicates observed and 0 indicates missing.

Usage

markov_two_states(p1 = NULL, p2 = NULL)

Arguments

p1

Transition probability from observed (1) to missing (0).

p2

Transition probability from missing (0) to observed (1).

Value

A missingness_model object.

Examples

mod <- markov_two_states(p1 = 0.05, p2 = 0.95)
mod
z <- generate(mod, n = 200, seed = 123)
plot(z)

gmwmx2 documentation built on June 10, 2026, 5:06 p.m.