ks_test_t | R Documentation |
Performs a two-sided KS test for H_0: X \sim t_{\nu}
with c
,
scale s
, and degrees of freedom \nu
. If parameters are not
specified, the MLE given the data will be used (see
fitdistr
).
For estimated parameters of the t-distribution the p-values are incorrect and
should be adjusted. See ks.test
and the references
therein (Durbin (1973)). As a more practical approach consider
bootstrapping and estimating the p-value empirically.
ks_test_t(x, param = NULL)
x |
a numeric vector of data values. |
param |
3-dimensional named vector |
A list of class "htest"
containing:
statistic |
the value of the Kolomogorv-Smirnov statistic. |
p.value |
the p-value for the test. |
alternative |
a character string describing the alternative hypothesis. |
method |
the character string "One-sample Kolmogorov-Smirnov test student-t" plus rounded parameter values. |
data.name |
a character string giving the name(s) of the data. |
fitdistr
, ks.test
set.seed(1021)
beta.true <- c(location = 0, scale = 1, df = 4)
xx <- rt(n = 1000, df = beta.true['df'])
ks_test_t(xx)
ks_test_t(xx, beta.true)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.