posterior_predictive_sample_comparison: Poisson model with gamma prior, compare the two parameters

Description Usage Arguments Value Examples

View source: R/posterior_predictive_sample_comparison.R

Description

Poisson model with gamma prior, compare the two parameters

Usage

1
2
3
4
posterior_predictive_sample_comparison(sample_size = sample_size,
  gamma_a1 = gamma_a1, gamma_b1 = gamma_b1, gamma_a2 = gamma_a2,
  gamma_b2 = gamma_b2, tildeya_smaller_than_tildeyb = TRUE,
  plot = FALSE)

Arguments

sample_size

How many samples to produce.

gamma_a1

First parameter of theta1.

gamma_b1

Second parameter of theta1.

gamma_a2

First parameter of theta2.

gamma_b2

Second parameter of theta2.

tildeya_smaller_than_tildeyb

How to make the comparison. If FALSE, compute theta1 > theta2.

plot

Whether to plot the figure showing the tendency of probability change.

Value

The probability vector or value

Examples

1
2
3
posterior_predictive_sample_comparison(sample_size = 5000, gamma_a1 = 237, 
gamma_b1 = 20, gamma_a2 = 12*(1:100)+113, gamma_b2 = 13+(1:100), 
tildeya_smaller_than_tildeyb = FALSE, plot = TRUE)

nathanxli/BayesPD documentation built on June 18, 2020, 4:38 a.m.