0
$\begingroup$

I am looking for a statistical test that assesses if two samples which have binary values come from the same source or from different ones.

Example:

I have one set that has 10 0s and 6 1s and another set which has 50 0s and 29 1s. I would like to test the two sets from belonging from the same source or are significantly different. What is the best one? Is t-test appropriate for this specific case?

$\endgroup$
2
$\begingroup$

This is a classical contingency table, where you would test independence with a standard chi-squared test. In R:

chisq.test(cbind(c(10,6),c(50,29)))

(Please don't do t-tests on discrete data. Every time you do this, a kitten dies...)

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.