Select menu: Stats | Statistical Tests | Randomization Test for Two Groups
This test performs a randomization test of the hypothesis that two groups have equal means. The randomization test is a method of testing this hypothesis without making any assumptions about the shape of the distribution (e.g. that it is Normal).
- After you have imported your data, from the menu select
Stats | Statistical Tests | Randomization Test for Two Groups. - Fill in the fields as required then click Run.
You can set additional Options then after running, you can save the results by clicking Store.
The randomization test works by randomly allocating the observations to two groups a large number of times. Each observation is used once, and randomly allocated to group 1 or 2, but with the restriction that the number of observations in groups 1 (n1) and 2 (n2) are the same as in the original sample. This is also known as permuting the group membership, as samples are random permutations of n1 ones and n2 twos. If there is no difference between the means of the two groups, the observed sample statistic should not be an extreme observation amongst the distribution sample of randomized statistics. The probability of the test is taken as the proportion of samples that is more extreme than the observed statistic.
Traditionally the observed statistic is taken as one of the results, so that the probability is the number of samples with a statistic that is the same or extreme than the observed sample divided by the number of samples = number of randomization samples plus one.
Available data
This lists data structures appropriate to the current input field. It lists either factors for specifying the groups, or variates for specifying the data. The contents will change as you move from one field to the next. Double-click a name to copy it into the input field, or type the name in directly.
Statistic
This is the statistic that is calculated for each sample.
Difference between means of two samples | The difference between means of samples where data are supplied by either two variates or a single variate with a group factor. The difference is evaluated as the mean of group 1 – mean of group 2. |
t-test of two samples | The t-test of the difference between means of samples where data are supplied by either two variates or a single variate with a group factor. The difference is evaluated as the mean of group 1 – mean of group 2. The t-test statistic divides the difference by its standard error. The type of test (one- or two-sided) and method for estimating the standard error are controlled in the Options dialog. |
Data arrangement
You can supply the data either as a pair of variates or as a single variate with a factor defining the groups.
Two variates | You must supply the samples as two separate variates, whose names should be entered as data variate 1and data variate 2. |
One variate with group factor | You must supply the data in one variate in the Data variate field. Membership of the two samples is then indicated by a groups factor whose name you will enter in the Groups factor field. |
Number of randomization samples
Number of times to randomize the group membership in forming the randomization distribution of the statistics.
Action Icons
Pin | Controls whether to keep the dialog open when you click Run. When the pin is down the dialog will remain open, otherwise when the pin is up the dialog will close. | |
Restore | Restore names into edit fields and default settings. | |
Clear | Clear all fields and list boxes. | |
Help | Open the Help topic for this dialog. |
See also
- Randomization test options for choosing options
- Randomization test store options for choosing the results to save
- TTEST procedure in command mode