[R] Vector of quantiles
Warnes, Gregory R
gregory_r_warnes at groton.pfizer.com
Mon Oct 14 21:45:36 CEST 2002
You should be able to do
ks.test( x, "pchisq", df=9)
to do a KS test on data 'x' against a chi-square with 9 df. For example,
> x <- rchisq(1000,df=9)
> ks.test( x, "pchisq", df=9)
One-sample Kolmogorov-Smirnov test
data: x
D = 0.0192, p-value = 0.8568
alternative hypothesis: two.sided
See the ks.test help page for more details.
-Greg
> -----Original Message-----
> From: Bayesianbay at aol.com [mailto:Bayesianbay at aol.com]
> Sent: Monday, October 14, 2002 1:11 PM
> To: r-help at stat.math.ethz.ch
> Subject: [R] Vector of quantiles
>
>
> I have a quick question which is very simple but I seem to
> have a mental
> block!
>
> I'm using the pchisq function to specify a Chi Squared
> distribution with 9 df
> which I'm then going to use in the Kolmogorov-Smirnov Test to
> test some
> simulated values.
>
> so simply: pchisq(q, df=9)
>
> I know that q is the vector of quantiles but could anybody
> tell me what
> exactly this vector needs to contain?
>
> Many Thanks
> Laura
> -.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.
> -.-.-.-.-.-.-.-.-
> r-help mailing list -- Read
> http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
> Send "info", "help", or "[un]subscribe"
> (in the "body", not the subject !) To:
> r-help-request at stat.math.ethz.ch
> _._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._.
> _._._._._._._._._
>
LEGAL NOTICE
Unless expressly stated otherwise, this message is confidential and may be privileged. It is intended for the addressee(s) only. Access to this E-mail by anyone else is unauthorized. If you are not an addressee, any disclosure or copying of the contents of this E-mail or any action taken (or not taken) in reliance on it is unauthorized and may be unlawful. If you are not an addressee, please inform the sender immediately.
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !) To: r-help-request at stat.math.ethz.ch
_._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._._
More information about the R-help
mailing list