View source: R/NNCTFunctions.R
| pk | R Documentation |
k items selected from the class with size n_1Returns the ratio n_1(n_1-1) \cdots (n_1-(k-1))/(n(n-1) \cdots (n-(k-1)),
which is the probability that the k selected
objects are from class 1 with size n_1 (denoted as n1 as an argument)
and the total data size is n.
This probability is valid under RL or CSR.
This function computes the p_k value which is required in the computation of the variance
of Cuzick and Edwards T_k test.
p_k is defined as the ratio n_1(n_1-1)\cdots (n_1-(k-1))/(n(n-1)\cdots (n-(k-1)).
The argument, n_1, is the number of cases (denoted as n1 as an argument).
The number of cases are denoted as n_1 and number of controls as n_0 in this function
to match the case-control class labeling,
which is just the reverse of the labeling in \insertCitecuzick:1990;textualnnspat.
See (\insertCitecuzick:1990;textualnnspat) for more details.
pk(n, n1, k)
pk(n, n1, k)
n |
A positive integer representing the number of points in the data set |
n1 |
Number of cases |
k |
Integer specifying the number of NNs (of subject |
Returns the probability of k items selected
from n items are from the class of interest
(i.e., from the class whose size is n_1)
Returns the p_k value. See the description.
Elvan Ceyhan
p11 and p12 etc.
asyvarTk, varTk, and varTkaij
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.