chitest.plot: Plot the Chi-square Test

View source: R/ch10-fn.R

chitest.plotR Documentation

Plot the Chi-square Test

Description

Plot the Result of the Chi-square Test

Usage

chitest.plot(stat, df, prng, side = "two", mt, dig = 4, ppt = 20)

Arguments

stat

Chi-square test statistic

df

Degree of freedom

prng

Range of x-axis

side

Type of the alternative hypothesis ("up", "low", "two"), Default: 'two'

mt

Graph title

dig

Number of digits below the decimal point, Default: 4

ppt

Number of plotting points in critical region, Default: 20

Value

None.

Examples

chi0 = var1.test(x=1.24, n=25, var0=0.8, side="up")
chitest.plot(stat=chi0$stat, df=chi0$df, side="up")

x = c(20.0, 21.5, 20.9, 19.8, 22.5, 20.3, 23.6, 18.0, 23.3, 17.8)
res = var1.test(x=x, var0=2, side="two")
chitest.plot(stat=res$stat, df=res$df, side="two")

adoocavo/Rstat_M1 documentation built on March 19, 2022, 3:34 a.m.