Description Usage Arguments Value Examples
View source: R/beta_sample_comparison.R
Sampling beta distributions and compare the two variables
1 2 | beta_sample_comparison(sample_size, beta_a1, beta_b1, beta_a2, beta_b2,
theta1_smaller_than_theta2 = TRUE, plot = FALSE)
|
sample_size |
How many samples to produce. |
beta_a1 |
First parameter of theta1. |
beta_b1 |
Second parameter of theta1. |
beta_a2 |
First parameter of theta2. |
beta_b2 |
Second parameter of theta2. |
theta1_smaller_than_theta2 |
How to make the comparison. If FALSE, compute theta1 > theta2. |
plot |
Whether to plot the figure showing the tendency of probability change. |
The probability vector or value. If the variables supplied consists of non-positive numbers, the program will ignore that pair of alpha and beta at the same time.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 | beta_sample_comparison(sample_size = 5000, beta_a1 = 58, beta_b1 = 44,
beta_a2 = 31, beta_b2 = 21)
beta_sample_comparison(sample_size = 6000, beta_a1 = c(58, 58), beta_b1 = c(44, 50),
beta_a2 = 31, beta_b2 = 21)
beta_sample_comparison(sample_size = 7000, beta_a1 = 58, beta_b1 = 44,
beta_a2 = c(31, 31), beta_b2 = c(21, 30))
beta_sample_comparison(sample_size = 8000, beta_a1 = 58, beta_b1 = 44,
beta_a2 = 31, beta_b2 = 21, theta1_smaller_than_theta2 = FALSE)
beta_sample_comparison(sample_size = 8000, beta_a1 = 58, beta_b1 = 44,
beta_a2 = 31, beta_b2 = 21, theta1_smaller_than_theta2 = FALSE, plot = TRUE)
beta_sample_comparison(sample_size = 9000, beta_a1 = 50:60, beta_b1 = 40:50,
beta_a2 = 31, beta_b2 = 21, plot = TRUE)
beta_sample_comparison(sample_size = 5000, beta_a1 = 58, beta_b1 = 44,
beta_a2 = 30:40, beta_b2 = 20:30, plot = TRUE)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.