test_cpv {robust2sls} | R Documentation |
Critical and p-value for test statistic relative to simulated distribution
Description
test_cpv
returns the critical value corresponding to a given
quantile of the simulated distribution and the p-value of the test statistic.
Usage
test_cpv(dist, teststat, p)
Arguments
dist |
A numeric vector of simulated values approximating the
distribution of the test statistic, e.g. generated as in |
teststat |
A numeric value of the test statistic. |
p |
A numeric vector of probabilities with values in [0,1] for which the corresponding quantiles are calculated. |
Value
A list with two named entries. $pval
is the p-value of the
test statistic with respect to the distribution dist
. $q
is the
vector of sample quantiles in the distribution dist
corresponding to
the probabilities specified in p
.
[Package robust2sls version 0.2.3 Index]