extract_spec: Extract the 'Specification' object used to object the model.

Description Usage Arguments Details Value Note See Also

Description

The extract_* family of methods returns elements from a fit object (including fixed and estimated quantities, as well as internal elements of the fit object).

Usage

1
extract_spec(object)

Arguments

object

An object returned by specify, hmm, compile, draw_samples, fit or optimizing.

Details

The extract_* family is the safest way to access the generated samples (filtered probability alpha, smoothed probability gamma, most likely hidden path zstar, observation samples from the posterior predictive density ypred, hidden path samples from the posterior predictive density zpred, simulated observations ysim), the fixed pre-specified quantities (observations y, time series length T, number of hidden states K, dimension of the observation vector R), Markov-chain Monte Carlo specific information (convergence and posterior predictive diagnostics diagnostics, number of chains n_chains, total iterations n_iterations, warm-up iterations n_warmup, thinning n_thin, sample size sample_size), and other internal elements stored in a fit object (Specification object spec, dataset in list format data, date date, time elapsed for fitting time, seed seed, path to the underlying Stan file filename). Except for MCMC-specific functions, these all work interchangeably with both Markov-chain Monte Carlo samples returned by draw_samples and maximum a posteriori estimates returned by optimizing.

Value

A Specification object.

Note

This function does not allow the arguments combine, reduce, and chain.

See Also

Other extract: extract_K, extract_R, extract_T, extract_alpha, extract_data, extract_filename, extract_gamma, extract_model, extract_obs_parameters, extract_parameters, extract_ypred, extract_ysim, extract_y, extract_zpred, extract_zsim, extract_zstar, extract


luisdamiano/BayesHMM documentation built on May 20, 2019, 2:59 p.m.