pDtrend | R Documentation |
D
This function computes \Pr(D \le k)
(\Pr(D \ge k)
), i.e.
lower (upper) cumulative probabilities for
D=\sum_{i=1}^{n} (R_i - i)^2
, the nonparametric trend statistic
proposed by \insertCiteLehmann75;textualskedastic, under the assumption
that the ranks R_i
are computed on a series of n
independent and
identically distributed random variables with no ties. The function may be
used to compute one-sided p
-values for the nonparametric test for
heteroskedasticity of \insertCiteHorn81;textualskedastic. Computation
time is extremely slow for n > 10
if usedata
is set to
FALSE
; thus a normal approximation is implemented, including a
continuity correction.
pDtrend(
k,
n,
lower.tail = TRUE,
exact = (n <= 10),
tiefreq = NA,
override = FALSE
)
k |
An integer of |
n |
A positive integer representing the number of observations in the series. |
lower.tail |
A logical. Should lower tailed cumulative probability be
calculated? Defaults to |
exact |
A logical. Should exact distribution of |
tiefreq |
A double vector corresponding to the value of |
override |
A logical. By default, the |
A double between 0 and 1 representing the probability/ies of D
taking on at least (at most) the value(s) in the names
attribute.
dDtrend
, horn
# For an independent sample of size 6, the probability that D is <= 50 is
# 0.8222
pDtrend(k = 50, n = 6)
# Normal approximation of the above with continuity correction is
# 0.8145
pDtrend(k = 50, n = 6, exact = FALSE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.