MakeGrid | R Documentation |
Computes a grid of points on the interval (0,1). This function is useful for constructing the "alpha-grid" used in various r-value computations.
MakeGrid(nunits, type = "log", ngrid = NULL, lower = 1/nunits, upper = 1 - lower)
nunits |
The number of units in the data for which r-values are to be calculated. |
type |
The type of grid; type can be set to |
ngrid |
a number specifying the number of grid points |
lower |
the smallest grid point; must be greater than zero |
upper |
the largest grid point; must be less than one |
If nunits
≤ 1000, the default number of grid points is
equal to nunits
. When nunits
> 1000, the default
number of grid points is determined by
1000 + 25*log(nunits - 1000)*(nunits - 1000)^{1/4}
.
A vector of grid points in (0,1).
Nicholas Henderson and Michael Newton
rvalues
alpha.grid <- MakeGrid(1000,type="uniform",ngrid=200) log.grid <- MakeGrid(40,type="log") log.grid hist(log.grid)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.