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).
extract_filename(object)
object | An object returned by |
---|
A character string with the path to file with the underlying Stan code.
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
.
This function does not allow the arguments combine, reduce, and chain.
browse_model
for viewing the code using your IDE.
Other extract: extract_K
,
extract_R
, extract_T
,
extract_alpha
, extract_data
,
extract_gamma
, extract_model
,
extract_obs_parameters
,
extract_parameters
,
extract_spec
, extract_ypred
,
extract_ysim
, extract_y
,
extract_zpred
, extract_zsim
,
extract_zstar
, extract