similar to: A question on chisq.test

Displaying 20 results from an estimated 6000 matches similar to: "A question on chisq.test"

2005 Jun 22
1
chisq test and fisher exact test
Hi, I have a text mining project and currently I am working on feature generation/selection part. My plan is selecting a set of words or word combinations which have better discriminant capability than other words in telling the group id's (2 classes in this case) for a dataset which has 2,000,000 documents. One approach is using "contrast-set association rule mining" while the
2005 Oct 20
3
numerical issues in chisq.test(simulate=TRUE) (PR#8224)
Hi, This report deals with p-values coming from chisq.test using the simulate.p=TRUE option. The issue is numerical accuracy and was brought up in previous bug reports 3486 and 3896. The bug was considered fixed but apparently was only mostly fixed. Just the typical problem of two values that are mathematically equal not ending up numerically equivalent. Consider this series of three 2x2
2017 Dec 28
1
Numerical stability in chisq.test
> On 28 Dec 2017, at 13:08 , Kurt Hornik <Kurt.Hornik at wu.ac.at> wrote: > >>>>>> Jan Motl writes: > >> The chisq.test on line 57 contains following code: >> STATISTIC <- sum(sort((x - E)^2/E, decreasing = TRUE)) > > The preceding 2 lines seem relevant: > > ## Sorting before summing may look strange, but seems to be >
2003 Dec 09
2
p-value from chisq.test working strangely on 1.8.1
Hello everybody, I'm seeing some strange behavior on R 1.8.1 on Intel/Linux compiled with gcc 3.2.2. The p-value calculated from the chisq.test function is incorrect for some input values: > chisq.test(matrix(c(0, 1, 1, 12555), 2, 2), simulate.p.value=TRUE) Pearson's Chi-squared test with simulated p-value (based on 2000 replicates) data: matrix(c(0, 1, 1,
2004 Mar 09
1
bug(?) in chisq.test
This is a message for whoever maintains "chisq.test": For an outcome more extreme than 2000 simulations, a Monte Carlo p-value of "< 2.2e-16" was printed. Ripley said the proper p-value for such cases should be 1/(B+1) = 1/2001. This can be easily fixed by adding "if(PVAL==0)PVAL <- 1/(B+1)" right after the following line in the code for chisq.test (in R
2006 Dec 02
1
Chi-squared approximation may be incorrect in: chisq.test(x)
I am getting "Chi-squared approximation may be incorrect in: chisq.test(x)" with the data bleow. Frequency distribution of number of male offspring in families of size 5. Number of Male Offspring N 0 518 1 2245 2 4621 3 4753 4 2476 5
2008 Nov 16
3
chisq.test with simulate.p.value=TRUE (PR#13292)
Full_Name: Reginaldo Constantino Version: 2.8.0 OS: Ubuntu Hardy (32 bit, kernel 2.6.24) Submission from: (NULL) (189.61.88.2) For many tables, chisq.test with simulate.p.value=TRUE gives a p value that is obviously incorrect and inversely proportional to the number of replicates: > data(HairEyeColor) > x <- margin.table(HairEyeColor, c(1, 2)) >
2003 Jul 16
1
The two chisq.test p values differ when the contingency table is transposed! (PR#3486)
Full_Name: Tao Shi Version: 1.7.0 OS: Windows XP Professional Submission from: (NULL) (149.142.163.65) > x [,1] [,2] [1,] 149 151 [2,] 1 8 > c2x<-chisq.test(x, simulate.p.value=T, B=100000)$p.value > for(i in (1:20)){c2x<-c(c2x,chisq.test(x, simulate.p.value=T,B=100000)$p.value)} > c2tx<-chisq.test(t(x), simulate.p.value=T, B=100000)$p.value > for(i in
2003 Mar 26
3
a statistic question about chisq.test()
Hi, In the chisq.test(), if the expected frequency for some categories is <5, there will be a warning message which says Warning message: Chi-squared approximation may be incorrect in: chisq.test(x, p = probs) I am wondering whether there are some methods to get rid of this mistake... Seems the ?chisq.test() doesn''t provide more options to solve this problem. Or, the only choice is
2012 Aug 20
1
The difference between chisq.test binom.test and pbinom
Hello all, I am trying to understand the different results I am getting from the following 3 commands: chisq.test(c(62,50), p = c(0.512,1-0.512), correct = F) # p-value = 0.3788 binom.test(x=62,n=112, p= 0.512) # p-value = 0.3961 2*(1-pbinom(62,112, .512)) # p-value = 0.329 Well, the binom.test was supposed to be "exact" and give the same results as the pbinom, while the chisq.test
2005 Jun 26
2
chisq.test using amalgamation automatically (possible ?!?)
Dear List, If any of observed and/or expected data has less than 5 frequencies, then chisq.test (Pearson's Chi-squared Test for Count Data from package:stats) gives warning messages. For example, x<-c(10, 14, 10, 11, 11, 7, 8, 4, 1, 4, 4, 2, 1, 1, 2, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1) y<-c(9.13112391745095, 13.1626482033341, 12.6623267638188, 11.0130706413029, 9.16415925139016,
2014 May 07
3
historical significance of Pr(>Chisq) < 2.2e-16
Where does the value 2.2e-16 come from in p-values for chisq tests such as those reported below? > Anova(cm.mod2) Analysis of Deviance Table (Type II tests) Response: Freq LR Chisq Df Pr(>Chisq) B 11026.2 1 < 2.2e-16 *** W 7037.5 1 < 2.2e-16 *** Age 886.6 8 < 2.2e-16 *** B:W 3025.2 1 < 2.2e-16 *** B:Age 1130.4 8 < 2.2e-16 *** W:Age 332.9 8 < 2.2e-16 *** --- Signif.
2018 Aug 21
1
bug report: inaccurate error message for stats::chisq.test
Hi, `stats::chisq.test` checks that x and y each have at least 2 levels AFTER filtering on complete cases. It makes sense but the error message is misleading : ?'x' and 'y' must have at least 2 levels? Here?s how to reproduce the issue : x <- structure(c(1L, 1L, 1L, 2L, 1L, 2L), .Label = c("0001", "0003"), class = "factor") y <-
2010 Aug 24
2
chisq.test on samples of different lengths
Hello, I am trying to see whether there has been a significant difference in whether people experienced damages from wildlife in two different years. I therefore have two columns: year 1: yes no no no yes yes no year 2: no yes no yes I wanted to do a chisq.test, but if I enter it this way: chisq.test(year1, year2) I get the error saying the columns are two different lengths. So then I tried
2005 Dec 20
2
2 x 2 chisq.test (PR#8415)
Full_Name: nobody Version: 2.2.0 OS: any Submission from: (NULL) (219.66.34.183) 2 x 2 table, such as > x [,1] [,2] [1,] 10 12 [2,] 11 13 > chisq.test(x) Pearson's Chi-squared test with Yates' continuity correction data: x X-squared = 0.0732, df = 1, p-value = 0.7868 but, X-squared = 0.0732 is over corrected. when abs(a*d-b*c) <= sum(a,b,c,d), chisq.value
2003 Jul 15
1
Why two chisq.test p values differ when the contingency table is transposed?
I'm using R1.7.0 runing with Win XP. Thanks, ...Tao ???????????????????????????????????????????????????????? >x [,1] [,2] [1,] 149 151 [2,] 1 8 >t(x) [,1] [,2] [1,] 149 1 [2,] 151 8 >chisq.test(x, simulate.p.value=T, B=100000) Pearson's Chi-squared test with simulated p-value (based on 1e+05 replicates) data: x X-squared = 5.2001, df =
2008 Feb 07
3
how to calculate chisq value in R
for example, an expression such as chisq(df=1,ncp=0) ? thanks -- View this message in context: http://www.nabble.com/how-to-calculate-chisq-value-in-R-tp15338943p15338943.html Sent from the R help mailing list archive at Nabble.com.
2012 Jun 26
5
chisq.test
Dear list! I would like to calculate "chisq.test" on simple data set with 70 observations, but the output is ''Warning message:'' Warning message: In chisq.test(tabele) : Chi-squared approximation may be incorrect Here is an example:         tabele <- matrix(c(11, 3, 3, 18, 3, 6, 5, 21), ncol = 4, byrow = TRUE)         dimnames(tabela) <- list(        
2009 May 09
2
need help with chisq
I am very new to R. I have some data from a CVS stored in vdata with 4 columns labeled: X08, Y08, X09, Y09. I have created two new "columns" like so: Z08 <- (vdata$X08-vdata$Y08) Z09 <- (vdata$X09-vdata$Y09) I would like to use chisq.test for each "row" and output the p-value for each in a stored variable. I don't know how to do it. Can you help? so far I have
2010 Aug 12
2
Difference in Monte Carlo calculation between chisq.test and fisher.test
Hello all, I would like to know what the difference is between chisq.test and fisher.test when using the Monte Carlo method with simulate.p.value=TRUE? Thank you -- View this message in context: http://r.789695.n4.nabble.com/Difference-in-Monte-Carlo-calculation-between-chisq-test-and-fisher-test-tp2322494p2322494.html Sent from the R help mailing list archive at Nabble.com.