Use the Power for Two Independent Sample Proportions Explorer to determine a sample size for a hypothesis test for proportions from two groups. Select DOE > Sample Size Explorers > Power > Power for Two Independent Sample Proportions. Explore the trade-offs between sample size, power, significance, and the hypothesized difference to detect. Sample size and power are associated with the following hypothesis test:

versus the two-sided alternative:

or versus either of the following one-sided alternatives:
or 
where p1 and p2 are the population proportions from two populations, and D0 is the hypothesized difference in proportions.
Set study assumptions and explore sample sizes by using the radio buttons, text boxes, and menus. The profiler updates as you make changes to the settings. Alternatively, you can change the settings by dragging the cross hairs on the profiler curves.
Test Type
Specifies a one- or two-sided hypothesis test.
Alpha
Specifies the probability of a type I error, which is the probability of rejecting the null hypothesis when it is true. It is commonly referred to as the significance level of the test. The default alpha level is 0.05.
The profiler enables you to visualize the impact of sample size assumptions on the power calculations. Interactive profiler changes to the sample sizes or proportions update the calculated power. Interactive changes to the profiler power update the sample sizes. To solve for a specific variable, use the target variable setting and click Go.
Target Variable
Enables you to solve for a sample size or a group proportion at a specified power.
Power
Specifies the probability of rejecting the null hypothesis when it is false. With all other parameters fixed, power increases as sample size increases.
Total Sample Size
Specifies the total number of observations (runs, experimental units, or samples) that are needed for your experiment.
Ratio of Group 2 to Group 1 Sample Size
Specifies the ratio between group sample sizes. For equal group sample sizes, set this option to 1.
Note: The ratio can shift as you explore changes to the assumptions due to the mathematical search routines.
Group 1 Sample Size
Specifies the number of observations (runs, experimental units, or samples) that are needed for Group 1 in your experiment.
Group 2 Sample Size
Specifies the number of observations (runs, experimental units, or samples) that are needed for Group 2 in your experiment.
Group 1 Proportion
Specifies the proportion that you assume for Group 1.
Group 2 Proportion
Specifies the proportion that you assume for Group 2.
The Explorer red triangle menu and report buttons provide additional options:
Simulate Data
Opens a data table of simulated data that are based on the explorer settings. View the simulated response column formula for the settings that are used. Run the table script to analyze the simulated data.
Make Data Collection Table
Creates a new data table that you can use for data collection. The table includes scripts to facilitate data analysis.
Remember Settings
Saves the current settings to the Remembered Settings table. This enables you to save a set of alternative study plans. See Remembered Settings in the Sample Size Explorers.
Reset to Defaults
Resets all parameters and graphs to their default settings.
The Profiler red triangle menu contains the following option:
Optimization and Desirability
Enables you to optimize settings. See “Desirability Profiling and Optimization” in Profilers.
Note: The sample size explorer report can be saved as a *.jmpdoe file. Open the file to return to the explorer. An alert prompts you to save the file.
In this example, use the Power Explorer for Two Independent Sample Proportions to evaluate the difference in testing 200 or 400 samples to determine the difference in misclassification rates of a diagnostic model that is applied at two different sites.
You would like to evaluate a hypothesis test with at least 80% power to test for the difference in proportions at a significance level of α = 0.05. Assume that the diagnostic test has a misclassification rate of 10% and consider total sample sizes of 200 and 400.
1. Select DOE > Sample Size Explorers > Power > Power for Two Independent Sample Proportions.
2. Leave Test Type set to Two-Sided.
3. Leave Alpha set to 0.05.
4. Select Group 2 Proportion for Target Variable.
5. Leave Power set to 0.8.
6. In the profiler, set Total Sample Size to 200. Note that the group sample sizes update to 100.
7. In the profiler, set Group 1 Proportion to 0.1. This is the assumed misclassification rate.
8. Click Go to solve for Group 2 Proportion.
9. Click Remember Settings to save the results showing that with 100 samples per group a misclassification rate of 0.25 would be found to be statistically significantly different from the 0.1 of Group 1. Maintain the default name and click OK.
10. Set Total Sample size to 400. Note the group sample sizes are each 200.
11. Click Go to solve for Group 2 Proportion.
12. Click Remember Settings to save the results showing that with 200 samples per group the misclassification rate of 0.20 would be found to be statistically significantly different from the 0.1 of Group 1. Maintain the default name and click OK.
Figure 29.5 Two Independent Sample Proportions Explorer
An increase in total sample size from 200 to 400 samples enables you to detect a 0.05 smaller difference in proportions between the two groups.
The power calculations for testing the difference in proportions from two sample groups are based on the normal approximation. The calculations depend on the form of the alternative hypothesis. For a one-sided, higher alternative (p1 > p2):

For a one-sided, lower alternative (p1 < p2):

For a two-sided alternative (p1 ≠ p2):


where:
α is the significance level
n1 and n2 are the group sample sizes
p1 and p2 are the group proportions
δ is the difference to detect
z1-α is the (1 - α)th quantile of the distribution
Φ(x) is the cumulative distribution function of the normal distribution.