GaPlotDiag {BGPhazard}R Documentation

Diagnosis plots for Lambda, U, C and Epsilon

Description

Diagnostics plots for hazard rate (Lambda), latent variable (U), dependence parameter (C) and the parameter of the hierarchical prior (Epsilon).

Usage

GaPlotDiag(M, variable = "Lambda", pos = 1)

Arguments

M

List. Contains the output by GaMRes.

variable

Either "Lambda", "U", "C" or "Epsilon". Variable for which informative plot will be shown.

pos

Positive integer. Position of the selected variable to be plotted.

Details

This function returns a diagnostics plot for which the chain of the selected variable can be monitored. Diagnostics includes trace, ergodic mean, autocorrelation function and histogram.

References

- Nieto-Barajas, L. E. & Walker, S. G. (2002). Markov beta and gamma processes for modelling hazard rates. Scandinavian Journal of Statistics 29: 413-424.

See Also

GaMRes

Examples



 
## Simulations may be time intensive. Be patient.

## Example 1
#  data(gehan)
#  timesG <- gehan$time[gehan$treat == "6-MP"]
#  deltaG <- gehan$cens[gehan$treat == "6-MP"]
#  GEX1 <- GaMRes(timesG, deltaG, K = 8, iterations = 3000)
#  GaPlotDiag(GEX1, variable = "Lambda", pos = 2)
#  GaPlotDiag(GEX1, variable = "U", pos = 5)

## Example 2
#  data(leukemiaFZ)
#  timesFZ <- leukemiaFZ$time
#  deltaFZ <- leukemiaFZ$delta
#  GEX2 <- GaMRes(timesFZ, deltaFZ, type.c = 4)
#  GaPlotDiag(GEX2, variable = "Lambda", pos = 2)
#  GaPlotDiag(GEX2, variable = "U", pos = 3)




[Package BGPhazard version 2.1.1 Index]