xdtransform {XDNUTS}R Documentation

Function to apply a transformation to the samples from the output of an XDNUTS model.

Description

Function to apply a transformation to the samples from the output of an XDNUTS model.

Usage

xdtransform(X, which = NULL, FUN = NULL, ..., new.names = NULL)

Arguments

X

an object of class XDNUTS.

which

a vector of indices indicating which parameter the transformation should be applied to. If NULL, the function is applied to all current iterations of the chain.

FUN

a function object which takes one or more components of an MCMC iteration and any other possible arguments.

...

optional arguments for FUN.

new.names

a character vector containing the parameter names in the new parameterization. If only one value is provided, but the transformation involves more, the name is iterated with an increasing index.

Value

an object of class XDNUTS with the specified transformation applied to each chain.


[Package XDNUTS version 1.2 Index]