Le 18/12/2017 à 15:41, HATMZAHARNA via R-help a écrit :
Please could you tell me how to make code to make chi-square distribution table?

Please help

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

To help you to begin to do a code that we could enhance, here are some functions that will be usefull for you:

> qchisq(p=1-0.05, df=1)
[1] 3.841459

Then, using a range of df, from example 1 to 10:

> qchisq(p=1-0.05, df=1:10)
 [1]  3.841459  5.991465  7.814728  9.487729 11.070498 12.591587 14.067140 15.507313 16.918978 18.307038

To help to present a nice table:

> X <- qchisq(p=1-0.05, df=1)
> format(X, digits = 4+log10(X), width = 10)
[1] "     3.841"

Or use the xtable package

Sincerely

Marc

______________________________________________
R-help@r-project.org mailing list -- To UNSUBSCRIBE and more, see
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to