Description Usage Arguments Details Value Examples
Repeat cycles of bootstrap resampling followed by density re-estimation for testing purposes.
1 | cycle_rvtable(x, n, start = NULL, density.args, sample.args, keep = "all")
|
x |
an rvtable in distribution form only. |
n |
total number of iteratively estimated distributions to return, including the original from |
start |
usually |
density.args |
optional arguments passed to |
sample.args |
optional arguments used when sampling. If supplied, overrides the |
keep |
character, iterations to retain in output table. Options are |
This function repeats cycles of bootstrap resampling from a distribution followed by distribution re-estimation n - 1
times.
x
must be a distribution-form rvtable and not a sample-form rvtable.
an rvtable.
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
library(dplyr)
x <- data.frame(
id1=rep(LETTERS[1:5], each=4),
id2=factor(c("low", "high")),
id3=rep(1:2, each=2),
Val=rep(1:10, each=20), Prob=rep(sqrt(1:10), each=20)) %>% rvtable
cycle_rvtable(x, 2)
x %>% group_by(id1, id2) %>% cycle_rvtable(3, keep="last")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.