as_mcmc_list: Coerce to an mcmc.list Object

View source: R/as-mcmc-list.R

as_mcmc_listR Documentation

Coerce to an mcmc.list Object

Description

Coerce an R object to an mcmc.list object.

Usage

as_mcmc_list(x, ...)

## S3 method for class 'mcmc'
as_mcmc_list(x, ...)

## S3 method for class 'nlist'
as_mcmc_list(x, ...)

## S3 method for class 'nlists'
as_mcmc_list(x, ...)

Arguments

x

An object.

...

Unused.

Value

An mcmc.list object.

Methods (by class)

  • as_mcmc_list(mcmc): Coerce an mcmc object to an mcmc.list object.

  • as_mcmc_list(nlist): Coerce an nlist object to an mcmc.list object.

  • as_mcmc_list(nlists): Coerce an nlists object to an mcmc.list object.

See Also

Other mcmc: as_mcmc()

Examples

as_mcmc_list(nlist(x = matrix(1:6, 2)))
as_mcmc_list(nlists(
  nlist(x = matrix(1:6, 2)),
  nlist(x = matrix(3:8, 2))
))

nlist documentation built on June 8, 2025, 9:41 p.m.