This function simulates data from a distribution and performs a one sample T-test then outputs coverage probability and type 1 error rate
1 2 | hw2.sim.849(h0.mean, num.samp, num.reps, samp.dist, times.scalar = FALSE,
alpha = 0.05, ...)
|
h0.mean |
The mean under H0 |
num.samp |
The number of samples in each repetition |
num.reps |
The number of repetitions |
samp.dist |
The distribution to sample from, either "normal", "chisq", or "t" |
times.scalar |
This is added for part g. If true, the function randomly samples a 5 or 10 for each repetition and multiples that by the first observation in that repetition's sample. |
alpha |
Alpha level for test |
... |
Additional options to specify for the sampling distribution |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.