wrong ttest result #463
-
|
Hi! I wanted to compare two groups using ttest function. The violin plot shows significant overlap, but the ttest from your package returns significant result.
T-test 3.828714 56 two-sided 0.000327 [0.16, 0.51] 1.00547 79.764 T-test 0.964251 When using scipy i get non-significant result. T-statistic: -1.2849905790443539, P-value: 0.20971011250741314 Why would that be? The latter result was also confirmed by another person in R. Thank you! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
Hi, I believe that the correct code to replicate the SciPy result is: import pingouin as pg
group1 = df[df["Skupina"] == 1]["masa"]
group2 = df[df["Skupina"] == 2]["masa"]
pg.ttest(group1, group2)Alternatively, you can use: import pingouin as pg
pg.pairwise_tests(data=df, dv="masa", between="Skupina") |
Beta Was this translation helpful? Give feedback.


Hi,
I believe that the correct code to replicate the SciPy result is:
Alternatively, you can use: