Description Usage Arguments Details Value Examples
Bootstrap confidience intervals with standard errors. bootstrap resamples dataset (e.g. diffusion coefficients) to calculate confidience intervals for a statistic measure of dataset.
1 | bootstrap(fittedObj,n.reps=100)
|
n.reps |
number of replicates for bootstrapping |
fittedObj |
output from fitNormDistr |
A wrapper of boot::boot and mixtools::boot.se adapted for data format in sojourner package. Also returns stderr information by running boot.se from mixtools and an additional method for one-component distribution calculates the stderr separately. For multi-component distributions, the boot.se function from the mixtools package was used. For single-component distributions, a separate function was used to calculate the stderr and confidence interval.
List of length 2 containing:
Fit results from fitNormDistr that was used as the input for the function
Bootstraps results from bootstrapping. mean values of each samples, standard error for the mean, lambda(proportion)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 | # read in using readDiatrack
folder=system.file("extdata","SWR1",package="sojourner")
trackll=readDiatrack(folder)
# filter track based length
trackll.flt=filterTrack(trackll,filter=c(min=5,max=Inf))
MSD=msd(trackll.flt,dt=6,summarize=FALSE,plot=TRUE)
dcoef=Dcoef(MSD=MSD,method="static",plot=FALSE)
# fit the dcoef result
fittedObj=fitNormDistr(dcoef)
# bootstrap new datasets
d.boot=bootstrap(fittedObj)
# manually set the number of bootstrap samples to 50
d.boot=bootstrap(fittedObj, n.reps=50)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.