One Tailed p Value

I’m using the Independent Groups t-Test extension, and my results are coming out with a 2-tailed p-value. I understand that this is the most often used version of this test, but I am specifically looking for a 1-tailed p-value (trying to prove that one group has a lower mean than the other, rather than just a different mean). The configuration page does not appear to contain an option for this, only allowing me to include a grouping column, group one, group two, and Confidence Interval. Is there an option that I’m missing, or is there maybe a community extension for t-test that has more functionality?

Hi @CKlinske

Welcome to the forum, thanks for your question.
I had a look and unfortunately I didn’t find a node that would return one-tailed p-value. Maybe @ipazin can confirm that.
What you could do to get there is using a scripting node like the R Snippet: https://kni.me/n/TQ-BN_cnxXhmciiQ
together with this function: https://www.rdocumentation.org/packages/stats/versions/3.6.2/topics/t.test

If you want to give a try, this video helps with the R integration in KNIME: https://www.youtube.com/watch?v=HtlpvydyZD0

Sorry I can’t come up with a better answer.

Best,
Alice

1 Like

Hello @CKlinske,

don’t think there is such a node as well. Another option apart from integrating R (or Python) within KNIME is to calculate one-sided p-values. (If I remember right this should be possible).

Found this:
“So, depending on the direction of the one-tailed hypothesis, its p-value is either 0.5*(two-tailed p-value) or 1-0.5*(two-tailed p-value) if the test statistic symmetrically distributed about zero.”

Br,
Ivan

Hello @ipazin
Based on above discussion jus want to confirm if my calculation is correct.
Ran a Independent group t-test

Got p value as 4.2 x 10(-4)
So if is a left sided test I am running p value becomes 2.1 x 10(-4)
Assuming confidence interval of 95% p=0.05
So the null hypothesis can be rejected since p<0.05

Appreciate your inputs here.

Hello @siddbksc,

and welcome to KNIME Community!

Well, would say yes but also would suggest to check it with proper statistician if it’s something important you are doing :sweat_smile:

Br,
Ivan