## Sampsize

Sample size for:

 Sample size for a study comparing means

 Mean 1 Mean 2 % Standard deviation 1 Standard deviation 2 % Power % (default 90%) Ratio n2/n1 (default 1) Alpha risk % (default 5%) One-sided test One-sample test Cluster sampling design: Intraclass correlation Number of clusters or, (not both) Number of observations

 Example 1: We wish to test the effects of a low-fat diet on serum cholesterol levels. We will measure the difference in cholesterol level for each subject before and after being on the diet. Since there is only one group of subjects, all on diet, this is a one-sample test. Our null hypothesis is that the mean of individual differences in cholesterol level will be zero; i.e., mdiff = 0mg/100ml. If the effect of the diet is as large as a mean difference of -10mg/100ml, then we wish to have power of 95% for rejecting the null hypothesis. Since we expect a reduction in levels, we want to use a one-sided test with alpha = 2.5%. Based on past studies, we estimate that the standard deviation of the difference in cholesterol levels will be about 20mg/100ml. To compute the required sample size, we enter 0 and -10 in the "Mean 1" and "Mean 2" fields, 20 in the "Standard deviation 1" field (leave "Standard deviation 2" blank), "Power" is 95, "Alpha risk" is 2.5, and we check both check boxes for one-sided and one-sample test. Sampsize returns an estimated sample size of n = 52. Note: One example of the use of the cluster design options is available here.   Example 2: We are doing a study of the relationship of oral contraceptives (OC) and blood pressure (BP) level for women ages 35-39. From a pilot study, it was determined that the mean and standard deviation BP of OC users were 132.86 and 15.34, respectively. The mean and standard deviation BP of OC users were 127.44 and 18.23. Since it is easier to find OC nonusers than users in the country were the study is conducted, we decide that n2, the size of the sample of OC users, should be twice n1, the size of the sample of OC users; that is, r = n2/n1 = 2. To compute the sample sizes for alpha = 5% (two-sided) and the power of 80%, we enter 132.86, 127.44, 15.34 and 18.23 in the first four fields, 80 in the "Power" field, 2 in the "Ratio n2/n1" field, and leave both check boxes unchecked. Sampsize returns an estimated sample size of n1 = 108 and n2 = 216.

 Power determination: means

 Mean 1 Mean 2 % Standard deviation 1 Standard deviation 2 % Sample size n1 Ratio n2/n1 (default 1) Alpha risk % (default 5%) One-sided test One-sample test

 Example 1: We decide to conduct the cholesterol study with n = 60 subjects, an we wonder what the power will be at a one-sided significance level of alpha = 1%. We type 0 and -10 in the "Mean 1" and "Mean 2" fields, respectively, 20 in the "Standard deviation 1" field, we leave the "Standard deviation 2" field blank since this is a one sample comparison of mean, we enter 60 in the "Sample size n1" field, 1 in the "Alpha risk" field, and we check both "One-sided test" and "One-sample test" check boxes. Sampsize returns an estimated power = 93.9%. Example 2: We now find that we only have enough money to study 100 subjects from each group for the oral contraceptives study. We can compute the power for n1 = n2 = 100 by entering 132.86, 127.44, 15.34 and 18.23 in the first four fields, 100 in the "Sample size n1" field, 1 in the "Ratio n2/n1" field, and leave both check boxes unchecked. Sampsize returns a power = 62.4%.

Goto index

© 2003-2005 Philippe Glaziou
`glaziou@gmail.com`
Sampsize project Homepage.