Pearson's Chi-squared test

data:  as.matrix(lotto)
X-squared = 46.61, df = 27, p-value = 0.01093


 Chi-square test of homogeneity for Lottery Data  

 Chi-square test of homogeneity for Prostate Data  

	Pearson's Chi-squared test

data:  stage4$rx and stage4$alive
X-squared = 6.0722, df = 3, p-value = 0.1081


 Fisher exact test for Prostate Data, dose 2 levels  

	Fisher's Exact Test for Count Data

data:  stage4$dose and stage4$alive
p-value = 0.1458
alternative hypothesis: true odds ratio is not equal to 1
95 percent confidence interval:
 0.2158128 1.2542057
sample estimates:
odds ratio 
 0.5453351 

[1] 0.2452669 1.2061661

 Cochran-Armitage Test for Prostate Data  

	Chi-squared Test for Trend in Proportions

data:  temp[, 1] out of temp[, 1] + temp[, 2] ,
 using scores: 1 2 3 4
X-squared = 1.9103, df = 1, p-value = 0.1669