What is the P-Value Formula?

P is a statistical measure that helps researchers to determine whether their hypothesis is correct. In addition, it helps determine the significance of the results. The null hypothesisNull HypothesisNull hypothesis presumes that the sampled data and the population data have no difference or in simple words, it presumes that the claim made by the person on the data or population is the absolute truth and is always right. So, even if a sample is taken from the population, the result received from the study of the sample will come the same as the assumption.read more is a default position that there is no relationship between two measured phenomena. H0 denotes it. An alternative hypothesis is the one you would believe if the null hypothesis is untrue. Its symbol is H1 or Ha.

P-value in excelP-value In ExcelP-value is used in correlation and regression analysis in Excel to determine whether the result obtained is feasible or not and which data set from the result to work with. It’s value ranges from 0 to 1.read more is a number between 0 and 1. In addition, tables, spreadsheet programs, and statistical software help calculate the P-value. The significance level (α) is a predefined threshold the researcher sets. It is generally 0.05. A very small P-value, which is lesser than the significance level, indicates that you reject the null hypothesis. The P-value, greater than the significance level, indicates that we fail to reject the null hypothesis.

Explanation of the P-Value Formula

One can derive the formula for the calculation of the P-Value by using the following steps:

Calculating P-Value from a Z Statistic

Step 1: We need to find out the test statistic z

You are free to use this image on you website, templates, etc., Please provide us with an attribution linkHow to Provide Attribution?Article Link to be HyperlinkedFor eg:Source: P Value Formula (wallstreetmojo.com)

Source: www.dummies.com

For instance, let us find the value of p corresponding to z ≥ 2.81. Since the normal distribution is symmetric, the negative values of z are equal to their positive values. 2.81 is a sum of 2.80 and 0.01. Look at 2.8 in the z column and the corresponding value of 0.01. We get p = 0.0025.

Examples of P-Value Formula (with Excel Template)

Let’s see some simple to advanced examples of the P-Value equation to understand it better.

Example #1

a) Since the P-Value of 0.3015 is greater than the significance level of 0.05 (5%), we fail to reject the null hypothesis.

b) Since the P-Value of 0.0129 is less than the level of significance of 0.05, we reject the null hypothesis.

Solution:

Use the following data for the calculation of P-Value.

P-Value will be –

a) Since the p-value of 0.3015 is greater than the level of significance of 0.05 (5%), we fail to reject the null hypothesis.

b) Since the p-value of 0.0129 is less than the level of significance of 0.05, we reject the null hypothesis.

Example #2

27% of people in India speak Hindi, as per a research study. A researcher is curious if the figure is higher in his village. Hence, the frames the null and alternative hypotheses. He tests H0: p = 0.27. Ha: p > 0.27. Here, p is the proportion of people in the village who speak Hindi. He commissions a survey in his village to find out the number of people who can speak Hindi. He finds that 80 out of 240 people sampled can speak Hindi. Find out the approximate P-Value for the researcher’s test if we were to assume that the necessary conditions are met, and the significance level is 5%.

Here, the sample size n = 240,

p0 is the population proportion. We will have to find the sample proportion

= 80 / 240

= 0.33

Z Statistic

Calculation of Z Statistic

=0.33 – 0.27 / √ 0.27 * (1 – 0.27 ) / 240

Z Statistic will be –

Z = 2.093696

P-Value = P (z ≥ 2.09)

We have to look at the value of 2.09 in the Z table. So, we have to look at -2.0 in the z column and the value in the 0.09 column. Since the normal distribution is symmetrical, the area to the right of the curve is equal to that on the left. So, we get the P-Value as 0.0183.

P Value = 0.0183

Since the P-Value is less than the significant level of 0.05 (5%), we reject the null hypothesis.

Example #3

Studies show that males buy a higher number of flight tickets as compared to females. Males and females buy them in a ratio of 2:1. The research was carried out at a particular airport in India to find the distribution of air tickets among males and females. Out of 150 tickets, 88 were bought by males and 62 by females. We need to determine if the experimental manipulation causes the change in the results or if we are observing a chance variation. Calculate the P-Value assuming the degree of significance is 0.05.

Step 1: The observed value is 88 for males and 62 for females.

  • Expected Value for males = 2/3* 150 = 100 malesExpected ValueExpected ValueExpected value refers to the anticipation of an investment’s for a future period considering the various probabilities. It is evaluated as the product of probability distribution and outcomes.read more for females = 1/3* 150 = 50 females

Step 2: Find out chi-square

=((88-100)2)/100 + (62-50) 2/50

=1.44+2.88

Chi-Square (X^2)

Chi-Square(X^2) will be –

Chi-Square(X^2) = 4.32

Step 3: Find the degrees of freedom

Since there are 2 variables – males and females, n=2

Degrees of freedom = n-1 = 2-1 = 1

Step 4:  From the P-Value table, we look at the first row in the table as the degree of freedom is 1. We can see that the P-Value is between 0.025 and 0.05. Since the P-Value is less than the degree of significance of 0.05, we reject the null hypothesis.

P Value = 0.037666922

Note: Excel directly gives the p-value using the formula:

CHITEST (actual range, expected range)

Example #4

It is known that 60% of the people who enter apparel stores in a city purchase something. An apparel shop owner wanted to find out if the number is higher for his apparel shop. He already had the results of a study conducted for his shop. 128 out of 200 people who entered his shop purchased something. The shop owner denoted the proportion of people who entered his apparel shop and purchased something. The null hypothesis he framed was p = 0.60, and the alternate hypothesis was p > 0.60. Find the P-Value for the research at a significance level of 5%.

Here, the sample size n = 200. We will have to find the sample proportion

= 128 / 200

= 0.64

= 0.64 – 0.60 / √ 0.60 * (1 – 0.60) /200

Z Statistic =1.1547

P Value = P (z ≥ 1.1547)

NORMSDIST will be –

NORMSDIST = 0.875893461

There is an inbuilt function to calculate a P-Value from a Z Statistic in Excel. It is known as the NORMSDIST function. The Excel NORMSDIST function calculates the standard normal cumulative distribution Function from a supplied value. Its format is NORMSDIST(z). Since the z-statistic value is in cell B2, the function used is = NORMSDIST(B2).

P Value will be –

P Value = 0.12410654

Since we have to find the area to the right of the curve,

P-Value = 1 – 0.875893 = 0.124107.

Since the P-Value of 0.124107 is more than a significant level of 0.05, we fail to reject the null hypothesis.

Relevance and Use

P-Value has wide applications in statistical hypothesis testingStatistical Hypothesis TestingHypothesis Testing is the statistical tool that helps measure the probability of the correctness of the hypothesis result derived after performing the hypothesis on the sample data. It confirms whether the primary hypothesis results derived were correct.read more, specifically null hypothesis testing. For instance, a Fund Manager runs a mutual fund. He claims that the returns from a particular mutual fund scheme are equivalent to Nifty, the benchmark stock market index. Therefore, he would frame the null hypothesis that the returns of the mutual fund scheme are equivalent to that of Nifty. The alternative hypothesis is that the Scheme and Nifty returns are not equivalent. He would then calculate the P-Value.

This article has been a guide to P-Value Formula. Here, we discuss calculating the P-Value and z-statistics with practical examples and a downloadable Excel template. You can learn more about Excel modeling from the following articles: –

  • Formula of Sample SizeFormula Of Sample SizeThe sample size formula depicts the relevant population range on which an experiment or survey is conducted. It is measured using the population size, the critical value of normal distribution at the required confidence level, sample proportion and margin of error.read moreNormal Distribution Formula | ExplanationNormal Distribution Formula | ExplanationNormal distribution is a distribution that is symmetric i.e. positive values and the negative values of the distribution can be divided into equal halves and therefore, mean, median and mode will be equal. It has two tails one is known as the right tail and the other one is known as the left tail.read moreFormula of Median in StatisticsFormula Of Median In StatisticsThe median formula in statistics is used to determine the middle number in a data set that is arranged in ascending order. Median ={(n+1)/2}thread moreCalculation of  Binomial Distribution