MATLAB Answers

laurie
0

ttest : independent and dependent samples

Asked by laurie
on 13 Feb 2013
hi
sorry this is a statistics question as well as a Matlab question...
i have two groups of data that i want to compare using ttest2. the two groups are independent. but among each group, there are some data-points that are dependent (because they come from the same samples).
so i guess that if i don't declare this, i get way more degrees of freedom (and hence significance) than what is "real". worst is, samples can be of very different sizes, and sometimes they can be huge (from 0 to more than 10000 data points per sample).
how can i declare to the ttest2 function that some data-points in both compared groups come from the same sample ? :-/
thank you..

  0 Comments

Sign in to comment.

1 Answer

Answer by Thorsten
on 13 Feb 2013
 Accepted Answer

If the two groups contain data from the same sample both groups are not independent. You can use paired-sample t-test if you have the same number of measurements in each group (like the same 100 patients before and after treatment). You seem to have some strange mixture were you cannot apply a t-test. I would suggest to throw away the dependent data points and then run a t-test on the remaining data.

  0 Comments

Sign in to comment.