NativeBuff2003
2009-Jul-27 23:01 UTC
[R] calculating p-values from t-values for a Bonferroni adjustment
I am performing a sequential bonferroni adjustment on the results of an ANCOVA but the equation I have for calculating p-values from the t-values is not working. I can't seem to find it anywhere else. This is the code I have now: 2*(1-pt(t,df)) where t=t-value and df=degrees of freedom from the ANCOVA. Is there an error in the code? maybe another way to find the p-values? Help! -- View this message in context: http://www.nabble.com/calculating-p-values-from-t-values-for-a-Bonferroni-adjustment-tp24689680p24689680.html Sent from the R help mailing list archive at Nabble.com.
Ben Bolker
2009-Jul-28 02:10 UTC
[R] calculating p-values from t-values for a Bonferroni adjustment
NativeBuff2003 wrote:> > I am performing a sequential bonferroni adjustment on the results of an > ANCOVA but the equation I have for calculating p-values from the t-values > is not working. I can't seem to find it anywhere else. This is the code I > have now: 2*(1-pt(t,df)) where t=t-value and df=degrees of freedom from > the ANCOVA. Is there an error in the code? maybe another way to find the > p-values? Help! >Please tell us what "not working" means and give a reproducible (?) example, etc., as discussed in the posting guide. Perhaps you have redefined the pt() function by accident? Works fine for me, e.g.> 2*(1-pt(2,10))[1] 0.07338803 2*pt(abs(x),df,lower.tail=FALSE) would be slightly more general/accurate. Ben Bolker -- View this message in context: http://www.nabble.com/calculating-p-values-from-t-values-for-a-Bonferroni-adjustment-tp24689680p24691288.html Sent from the R help mailing list archive at Nabble.com.
Possibly Parallel Threads
- Partek has Dunn-Sidak Multiple Test Correction. Is this the same/similar to any of R's p.adjust.methods?
- wilcoxon test with bonferroni correction
- Bonferroni simultaneous confidence intervals for multiple regression
- bonferroni en R
- p.adjust(<NA>s), was "Re: [BioC] limma and p-values"