Equally Sampling Groups

I’m trying to run a T-test comparing campus and online students but I have more online students. Is there a way to create a sample that randomly pulls the same number of respondents from each category? For example, 500 online and 500 campus responses.

Best,

Camaal M.

Hi Camaal,

You can use group-by step and then sample step, to sample the same number of rows from multiple groups like this screenshot.

1 Like

That did the trick. Thank you!

As a side note on t-test, it takes the sample sizes of both groups into account and gives appropriate test results. So, sampling down the data to make the sizes of groups balanced would not be necessary in this case.