Visualise prop.test
for testing the null that the proportions (probabilities of success)
in several groups are the same, or that they equal certain given values.
ggproptest(t, alpha=0.05,colaccept="lightsteelblue1", colreject="gray84", colstat="navyblue")
t | a list result of |
---|---|
alpha | alpha level for ploting distribution, when prop.test is used on more than 2 samples |
colaccept | color the acceptance area of the test |
colreject | color for the rejection area of the test |
colstat | color for the test statistic vline |
#> Warning: Chi-squared approximation may be incorrectpr_test#> #> 3-sample test for equality of proportions without continuity #> correction #> #> data: x out of y #> X-squared = 3.4538, df = 2, p-value = 0.1778 #> alternative hypothesis: two.sided #> sample estimates: #> prop 1 prop 2 prop 3 #> 0.6250000 0.8888889 0.9230769 #>ggproptest(pr_test)