On 28/03/2008, at 11:14 AM, Peter Dalgaard wrote:

> Michael A. Miller wrote:
>>>>>>> "James" == James Root <[EMAIL PROTECTED]> writes:
>>>>>>>
>>
>>> Is there a way to run all paired t-tests where a paired
>>> t-test is run for every possible combination?
>>
>> Sounds like pairwise.t.test is the sort of thing you are looking
>> for...
>>
>>
> Yes, except that it was designed for independent samples t-tests,  
> so you
> need to be careful about not mixing up the pairs. This appears to  
> do the
> trick:
>
>> pairwise.t.test(a,col(a),paired=T,pool=F,p.adj="none")
>
>         Pairwise comparisons using t tests with non-pooled SD

        <snip>

I would very strongly call this a bug in pairwise.t.test.  One should
*not* have to specify pool=FALSE if one is doing a paired t-test.  For
a paired t-test there is actually only *one* sample (the sample of  
pairwise
differences) and hence only one standard deviation, and hence nothing  
to pool.

My reading of the code is that if pool.sd is TRUE (the default) then the
pairwise.t.test function does two-independent-sample t-tests willy- 
nilly,
and ignores the ``paired=TRUE'' argument.  (It doesn't call upon  
t.test()
which is the only bit which considers the ``paired'' argument.)

This is a dangerous trap, and should be fixed.  (Which is not hard.)

                        cheers,

                                Rolf

######################################################################
Attention:\ This e-mail message is privileged and confid...{{dropped:9}}

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to