mapi
Mechanical
- Jan 30, 2007
- 53
Hi,
Data A from group 1 and B from group 2. Now mean(A) is larger than mean(B). We want to compare the two groups:
In Matlab, ttest2 is used:
To test if A is greater than B:
p=ttest2(A,B,0.05,'right') give p=0.045<0.05, so mean of A is statistically greater than mean of B.
To test if mean of A is equal to mean of B:
p=ttest2(A,B,0.05,'both') give P=0.07>0.05, so A and B are not statistically different from each other.
Which answer should I use?
Thanks,
Mapi
Data A from group 1 and B from group 2. Now mean(A) is larger than mean(B). We want to compare the two groups:
In Matlab, ttest2 is used:
To test if A is greater than B:
p=ttest2(A,B,0.05,'right') give p=0.045<0.05, so mean of A is statistically greater than mean of B.
To test if mean of A is equal to mean of B:
p=ttest2(A,B,0.05,'both') give P=0.07>0.05, so A and B are not statistically different from each other.
Which answer should I use?
Thanks,
Mapi