Displaying 15 results from an estimated 15 matches similar to: "Why two chisq.test p values differ when the contingency"
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 =
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 Aug 21
0
The two chisq.test p values differ when the contingency table (PR#3896)
>>>>> dmurdoch writes:
>> Date: Wed, 16 Jul 2003 01:27:25 +0200 (MET DST)
>> From: shitao@ucla.edu
>>> 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)}
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
>
2019 Sep 20
0
sscanf/stroul (was: Re: [PATCH nbdkit v3 2/3] Add new retry filter.)
On Thu, Sep 19, 2019 at 11:32:47AM -0500, Eric Blake wrote:
> > +static int
> > +retry_config (nbdkit_next_config *next, void *nxdata,
> > + const char *key, const char *value)
> > +{
> > + int r;
> > +
> > + if (strcmp (key, "retries") == 0) {
> > + if (sscanf (value, "%d", &retries) != 1 || retries < 0)
2020 Jan 07
3
Calling function from non-default floating-point environment
Hi all,
Implementation of #pragma STDC FENV_ACCESS raises a problem: what to do if
a function is called inside a region where FP environment differs from the
default? If the function expects default FP mode it may work incorrectly in
such case.
The C2x standard draft (
http://www.open-std.org/jtc1/sc22/wg14/www/docs/n2454.pdf) states (7.6p4):
Certain programming conventions support the intended
2001 Feb 14
0
ASPI problem
Having gotten WinOnCD to start (though the installer fails (*.msi
file)) by copying the files and registry from a windows install, I now
have an ASPI problem. I am able to erase a cdrw from within winoncd
and most of winoncd works pretty much as it should (but no drag'n drop
works). Writing a CD does however not work yet and it appears to be a
winaspi problem:
Here is part of the trace:
2008 Jun 03
1
Model simplification using anova()
Hello all,
I've become confused by the output produced by a call to
anova(model1,model2). First a brief background. My model used to predict
final tree height is summarised here:
Df Sum Sq Mean Sq F value Pr(>F)
Treatment 2 748.35 374.17 21.3096 7.123e-06 ***
HeightInitial 1 0.31 0.31 0.0178 0.89519
2008 Mar 21
0
How to Package Extra Results to summary.lm
Dear R users,
I came up with some simple functions to give me the standard betas and
tolerance values from a predefined lm() model. I have been trying to
insert the results from these functions into the coefficients matrix in
a modified summary.lm function that I'm calling summary2 (I'd never edit
the summary.lm function directly!!). I managed to get the results
inserted into the
2020 Mar 05
3
Should rint and nearbyint be always constrained?
+cfe-dev as the discussion is now biased toward C standard.
I'm not sure what problem you see here. In default mode, i.e.
> when there is no "#pragma STDC FENV_ACCESS on" in effect,
> then the compiler can always assume that the default rounding
> mode is in effect.
Well, if #pragma STDC FENV_ACCESS on is not in effect, that means
> that the user has promised that at
2019 Sep 19
5
Re: [PATCH nbdkit v3 2/3] Add new retry filter.
On 9/19/19 10:26 AM, Richard W.M. Jones wrote:
> This filter can be used to transparently reopen/retry when a plugin
> fails. The connection is closed and reopened which for most plugins
> causes them to attempt to reconnect to their source.
>
> For example if doing a long or slow SSH copy:
>
> nbdkit -U - ssh host=remote /var/tmp/test.iso \
> --run 'qemu-img
2010 Feb 26
2
Loop overwrite and data output problems
Hello R users,
I have been using R for a while now for basic stats but I'm now trying to
get my head around looping scripts and in some places I am failing!
I have a data set with c. 1200 data points on 98 individual animals with
data on each row representing a daily measure and I am asking the question
"what variables affect the animal's behaviour?"
the dataset includes
2023 Feb 17
2
fseek/fgetc puzzle
Hi all.
I've got a bit of a puzzle and I was wondering if anyone has any insight
as to what's going on.
I added some code to ssh's known_hosts handling that checks if the last
byte in the file is a newline, and if not, it adds one before writing
the new record. I also wrote a regression test for this and in most
cases this works fine.
On some platforms (Solaris, OpenIndiana and
2002 Oct 08
2
Memory fault on HP-UX 11.0, 3.4p1
Is this a known issue? (ignore the pervasive MS-outlook capitalization)
Ssh-agent /bin/ksh
Ssh-add /root/.ssh/id_rsa
Blah blah
Ssh -vvv some_server date
...
debug1: ssh_rsa_verify: signature correct
debug1: kex_derive_keys
debug1: newkeys: mode 1
debug1: Enabling compression at level 6.
debug1: SSH2_MSG_NEWKEYS sent
debug1: waiting for SSH2_MSG_NEWKEYS
debug1: newkeys: mode 0
debug1:
2007 Sep 12
1
reshape help
Hi,
I'm trying to use reshape but I cannot quite understand how it works.
Could somebody help me on this? Example, my data is something like:
mydat <- data.frame(tree= 1:10, serra=rep(1:2, c(5,5)), bt01= 101:110,
bt02= 201:210, bt03= 301:310, mm01= 9101:9110, mm02= 9201:9210, mm03=
9301:9310)
> mydat
tree serra bt01 bt02 bt03 mm01 mm02 mm03
1 1 1 101 201 301 9101 9201