credibleIntervals: Calculates credible intervals for preferences

Description Usage Arguments Value Author(s) Examples

Description

This function calculates the credible intervals for preference parameters for individuals and the population using the object created by the function bayesPref.

Usage

1
credibleIntervals(prefres = NULL, burn = 0, interval = 0.95)

Arguments

prefres

An object returned by bayesPref.

burn

A value indicating the number of burnin samples discarded.

interval

A value between 0 and 1 indicating the size of the credible interval calculated.

Value

A list containing the following

IndPref

An array containing the lower credible interval, the median, and upper credible interval for the individual-level preference parameters.

PopPref

An array containing the lower credible interval, the median, and upper credible interval for the population-level preference parameters.

PopVar

A vector for the lower credible interval, the median, and upper credible interval for the variance of the population-level preference parameters (variance of alphas in Dirichlet).

Author(s)

Zachariah Gompert zgompert@uwyo.edu, James A. Fordyce jfordyce@utk.edu

Examples

1
2
3
4
5
6
## Not run: 
data(YGGV)
res <- bayesPref(pData=YGGV,mcmcL=1000)
credibleIntervals(prefres=res[[1]],burn=100) #credible intervals for population 1

## End(Not run)

bayespref documentation built on May 2, 2019, 11:28 a.m.