# Sample Size Calculator

Confidence Level
Confidence Interval
%
Population
Sample Size  =  4.6099%
CALCULATE

Sample size calculator calculates the sample size in order to design statistics data research experiments. It's an online statistics and probability tool requires confidence level, confidence interval, and the population proportion to determine sample size to perform t-test, anova test, etc. The increased samples always yield better results.

It is necessary to follow the next steps:

1. Enter confidence level, the confidence interval, and population proportion in the box. The confidence level value is on of the values: $90\%$, $95\%$, and $99\%$. The confidence interval value must be real non-zero number and population proportion must be in $[0,1]$.
2. Press the "GENERATE WORK" button to make the computation.
3. Sample size calculator will give minimum number of necessary samples to meet the statistical constraints.
Input : Three numbers confidence level, the confidence interval, and population;
Output : A positive integer.

Sample Size Formula:
The sample size, n is determined by the formula $$n=\frac{z^2p(1-p)}{ME^2}$$ where z is the z-score associated with the confidence level, ME is the margin of error, also known as the confidence interval, and p is the sample proportion.

## What is Sample Size?

Sample size, denoted by a positive integer n, is one of the key aspects in statistical data analysis. The main objective of the sample size is to draw the assumption of a population by using the sample data. It determines how much sample data from the population is required to have the statistical experiments results more meaningful. The sample size calculation comes into effect wherever the experiment is not getting the complete population data for data analysis. It's mainly used in sample standard deviation calculation to determine a total number of samples required from the population to design the experiments like clinical, material and chemical compound data analysis. It depends on the confidence level and accuracy of experiments.

Margin of error also known as the confidence interval provides a range of values which is likely to contain the population parameter of interest.

An interval estimate of a parameter is an interval within which the value of a parameter of a population has a stated probability of occurring. This estimate may or may not contain the value of the parameter being estimated.

A confidence level of interval estimate of a parameter is the probability that the interval estimate contains the parameter. A confidence interval is the specific interval estimate of the parameter determined by using data obtained from a sample and by using the specific confidence level of the estimate. A $c\%$ confidence interval depends on the sample. A confidence interval may or may not contain the population mean. A $c\%$ confidence interval contains the population mean for $c\%$ of samples whose elements are chosen randomly and independently. The most common used confidence intervals are: $90\%$, $95\%$, and $99\%$.

The Central Limit Theorem states that when the sample size is large, approximately $95\%$ of the sample, means have $\pm 1.96$ standard errors of the population mean, i.e., $\mu\pm1.96\Big(\frac{\sigma}{\sqrt{n}}\Big).$ If a specific sample mean is selected, there is a $95\%$ probability that it falls within the range of $\mu\pm1.96\Big(\frac{\sigma}{\sqrt{n}}\Big).$
This means that there is a $95\%$ probability that $\mu$ belongs to the interval

$$(\mu-1.96\Big(\frac{\sigma}{\sqrt{n}}\Big),\mu+1.96\Big(\frac{\sigma}{\sqrt{n}}\Big))$$
• For a $90\%$ confidence interval, $\mu$ belongs to the interval
$$(\mu-1.65\Big(\frac{\sigma}{\sqrt{n}}\Big),\mu+1.65\Big(\frac{\sigma}{\sqrt{n}}\Big)$$
• For a $95\%$ confidence interval, $\mu$ belongs to the interval
$$(\mu-1.96\Big(\frac{\sigma}{\sqrt{n}}\Big),\mu+1.96\Big(\frac{\sigma}{\sqrt{n}}\Big))$$
• For a $99\%$ confidence interval, $\mu$ belongs to the interval
$$(\mu-2.58\Big(\frac{\sigma}{\sqrt{n}}\Big),\mu+2.58\Big(\frac{\sigma}{\sqrt{n}}\Big))$$
z is the critical value for the confidence level $c\%$. It is the z-value for which the interval from -z to z is the middle $c\%$ of the standard normal distribution.
Some critical values for $c\%$ are given in the following. For the other confidence levels, we need to consult the z-table.
Confidence level ($c\%$)z-value
80%1.28
85%1.44
90%1.65
95%1.96
99%2.58

### How to Calculate Sample Size?

To calculate a sample size, $n$, we use the following formula

$$n=\frac{z^2p(1-p)}{ME^2}$$
where z is the z-score associated with the confidence level, $ME$ is the margin of error, also known as the confidence interval, and $p$ is the sample proportion.
The variable that estimates $p$, a proportion of the population that has some property, is the sample proportion
$$\hat p=\frac{\mbox{number of successes in the sample}}{\mbox{total number of members in the sample}}$$
The below solved example may be useful to understand how the values are being used in the mathematical formulas to determine how much the sample size of a population is required to design an experiment produces reliable estimation. z-score gets changed based on the confidence level, so it is needed to carefully select the z-score for the expected confidence level.

Problem : The result of experiment shows that $50\%$ of Singapore people under the age of $55$ to $60$ living their life hassle-free. To design a similar survey in the United States of America, what is the required sample size to have $95\%$ confidence interval and margin error of $0.06$.

Solution : It is given $p=0.5$, confidence level $95\%$, and margin error of $0.06$. So the z-score is 1.96 for $95\%$ confidence interval. By substituting the given data, in the main equation, we obtain
$$n=\frac{z^2p(1-p)}{ME^2}=\frac{1.96^2 0.5\cdot0.5}{0.06^2}=266.77$$
The nearest round number is $267$. The required sample size to design the experiment to have $95\%$ confidence interval is 267.

The sample size calculator, formulas, solved example with step by step calculation to find the sample size, calculated from the confidence level of $90\%$, confidence interval of $12\%$ and population proportion of $5\%$. For any other values, just supply three corresponding inputs and click on the "GENERATE WORK" button. The grade school students may use this sample size calculator to generate the work, verify the results derived by hand or do their homework problems efficiently. Sample size estimation can be useful for grade school students as one of the major aspects in statistics & probability to design the experiments to provide a better assumption.

### Real World Problems Using Sample Size

Sample size gives us the number of participants or observations included in an experiment. The sample size has two important statistical properties:

• the precision of estimating;
• the power of the study to derive conclusions.
Sample size can be important for planning and can be interpreting in any field of research. It is also one of the most important things in creating surveys. It is important to use a correct sample size for our survey based on the population proportion, margin of error and confidence level.

### Sample Size Practice Problems

Practice Problem 1:
Find the minimum sample size required in order to estimate three percentage points, the proportion of voters who intend to vote for a presidential candidate with $95\%$ confidence.

Practice Problem 2:
Find the minimum sample size required to estimate the proportion of adults who have consulted a fortune teller. The confidence is $99\%$ and the margin error is $0.06$. Earlier studies give an estimate of $0.17$ for the population proportion.

The sample size is important in the field of statistical data analysis to increase the precision of estimates. The manual calculations can be done by using the above formulas. However, when it comes to online to verify the results or to perform such calculations, this sample size calculator makes calculations as simple as possible. The sample size formulas solved example problem along with step by step calculation would be very useful for grade school students (K-12 education) to understand how the population proportion, margin of error and confidence level values are being used in such calculations.