Description Usage Arguments Value Examples
View source: R/AoristicFunctions.R
This function generates aoristic circular data from a true distribution generation function and two function to generate the lower and upper distances from the true point.
1 2 3 4 5 | generateAoristicData(n = 30, trueDistGen = function(n)
as.numeric(suppressWarnings(circular::rvonmises(n, 1, 10))),
intervalSampler = function(n) runif(n, 0, 2),
LBSampler = intervalSampler, UBSampler = intervalSampler,
aoristicProportion = 1)
|
n |
The desired sample size. |
trueDistGen |
A function that takes a single argument n and samples n random values from the desired true distribution. |
intervalSampler |
A function that takes a single argument n and samples n random values that determine how far away the interval bounds are from the true sampled datapoint on either side. By default the same function is used on both sides, but this can be overwritten by specifying LBSampler and UBSampler. |
LBSampler |
Optional function of the same form as intervalSampler that specifies the way in which the distance between the lower bound and the true value is sampled. Should sample positive values which represent the difference. |
UBSampler |
Optional function of the same form as intervalSampler that specifies the way in which the distance between the upper bound and the true value is sampled.Should sample positive values which represent the difference. |
A data frame containing the start, end, and true values.
1 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.