Title: | Efficiently Generates Random Order Statistic Variables |
---|---|
Description: | All the methods in this package generate a vector of uniform order statistics using a beta distribution and use an inverse cumulative distribution function for some distribution to give a vector of random order statistic variables for some distribution. This is much more efficient than using a loop since it is directly sampling from the order statistic distribution. |
Authors: | Christian Sims <[email protected]> |
Maintainer: | Christian Sims <[email protected]> |
License: | GPL-2 |
Version: | 0.1.0 |
Built: | 2024-11-17 03:38:56 UTC |
Source: | https://github.com/cran/orderstats |
Gets order statistics from a 0-1 uniform distribution
order_probs(draw_size, k, n)
order_probs(draw_size, k, n)
draw_size |
- The size of the output sample |
k |
- The Kth smallest value from a sample |
n |
- The size the sample to compute the order statistic from |
A vector of random order statistic variables from a 0-1 uniform distribution
Gentle, James E. (2009), Computational Statistics, Springer, p. 63, ISBN 9780387981444
Gets random order statistics from a cauchy distribution
order_rcauchy(draw_size = 1, location = 0, scale = 1, k = 1, n = 1)
order_rcauchy(draw_size = 1, location = 0, scale = 1, k = 1, n = 1)
draw_size |
- The size of the output sample |
location |
- The location parameter in the cauchy distribution |
scale |
- The scale parameter in the cauchy distribution |
k |
- The Kth smallest value from a sample |
n |
- The size of the sample to compute the order statistic from |
A vector of random order statistic variables from a cauchy distribution
order_rcauchy(10, 0, 1, 100, 10000)
order_rcauchy(10, 0, 1, 100, 10000)
Gets random order statistics from a chi-square distribution
order_rchisq(draw_size, df, k, n)
order_rchisq(draw_size, df, k, n)
draw_size |
- The size of the output sample |
df |
- The degrees of the chi-square distribution |
k |
- The Kth smallest value from a sample |
n |
- The size of the sample to compute the order statistic from |
A vector of random order statistic variables from a chi-square distribution
order_rchisq(10, 1, 100, 10000)
order_rchisq(10, 1, 100, 10000)
Gets random order statistics from an exponential distribution
order_rexp(draw_size, rate, k, n)
order_rexp(draw_size, rate, k, n)
draw_size |
- The size of the output sample |
rate |
- The shape parameter in the exponential distribution |
k |
- The Kth smallest value from a sample |
n |
- The size of the sample to compute the order statistic from |
A vector of random order statistic variables from an exponential distribution
order_rexp(10, 0.005, 100, 10000)
order_rexp(10, 0.005, 100, 10000)
Gets random order statistics from a gamma distribution
order_rgamma(draw_size, shape, scale, k, n)
order_rgamma(draw_size, shape, scale, k, n)
draw_size |
- The size of the output sample |
shape |
- The shape parameter in the gamma distribution |
scale |
- The scale parameter in the gamma distribution |
k |
- The Kth smallest value from a sample |
n |
- The size of the sample to compute the order statistic from |
A vector of random order statistic variables from a gamma distribution
order_rgamma(10, 20, 2, 100, 10000)
order_rgamma(10, 20, 2, 100, 10000)
Gets random order statistics from a logistic distribution
order_rlogis(draw_size, location, scale, k, n)
order_rlogis(draw_size, location, scale, k, n)
draw_size |
- The size of the output sample |
location |
- The location parameter in the logistic distribution |
scale |
- The scale parameter in the logistic distribution |
k |
- The Kth smallest value from a sample |
n |
- The size of the sample to compute the order statistic from |
A vector of random order statistic variables from a logistic distribution
order_rlogis(10, 0, 1, 100, 10000)
order_rlogis(10, 0, 1, 100, 10000)
Gets random order statistics from a normal distribution
order_rnorm(draw_size = 1, mean = 0, sd = 1, k = 1, n = 1)
order_rnorm(draw_size = 1, mean = 0, sd = 1, k = 1, n = 1)
draw_size |
- The size of the output sample |
mean |
- The mean of the normal distribution |
sd |
- The standard deviation of the normal distribution |
k |
- The Kth smallest value from a sample |
n |
- The size of the sample to compute the order statistic from |
A vector of random order statistic variables from a normal distribution
order_rnorm(10, 0, 1, 100, 10000)
order_rnorm(10, 0, 1, 100, 10000)