Normal distribution
Here's how we get the normal probability distribution function.
 ![Plot[PDF[NormalDistribution[0, 1], x], {x, -3, 3}]](../HTMLFiles/normal_21.gif) 
 ![[Graphics:../HTMLFiles/normal_22.gif]](../HTMLFiles/normal_22.gif) 
  
The following definition returns the area (Cumulative Distribution Function) of the "standard normal distribution", i.e. a Gaussian with μ=0 and σ=1. These are the numbers in table D-4 in the Understanding Statistics text, which is the probability for a value at or below the given z.
 ![prob[z_] := CDF[NormalDistribution[0, 1], z] ;](../HTMLFiles/normal_24.gif) 
 ![Plot[prob[z], {z, -3, 3}]](../HTMLFiles/normal_25.gif) 
 ![[Graphics:../HTMLFiles/normal_26.gif]](../HTMLFiles/normal_26.gif) 
  
 ![RowBox[{prob, [, RowBox[{-, 2.58}], ]}]](../HTMLFiles/normal_28.gif) 
  
Since this is in the z<0 range, its the same as the NormalPValue result.
 ![RowBox[{NormalPValue, [, RowBox[{-, 2.58}], ]}]](../HTMLFiles/normal_30.gif) 
 ![RowBox[{OneSidedPValue, , 0.00494002}]](../HTMLFiles/normal_31.gif) 
But on the positive side we have
 ![RowBox[{prob, [, 2., ]}]](../HTMLFiles/normal_32.gif) 
  
 ![RowBox[{NormalPValue, [, 2., ]}]](../HTMLFiles/normal_34.gif) 
 ![RowBox[{OneSidedPValue, , 0.0227501}]](../HTMLFiles/normal_35.gif) 
 ![1 - OneSidedPValue/.NormalPValue[2]](../HTMLFiles/normal_36.gif) 
  
To find the inverse function, Mathematica uses the Quantile property of a distribution, which returns the z value where the distribution accumulates a given total probability. So to find out the z value such that the probability below that z is 0.9775, we do this.
 ![quan[p_] := Quantile[NormalDistribution[0, 1], p]](../HTMLFiles/normal_38.gif) 
 ![RowBox[{quan, [, 0.97725, ]}]](../HTMLFiles/normal_39.gif) 
  
 ![Plot[quan[p], {p, 0, 1}]](../HTMLFiles/normal_41.gif) 
 ![[Graphics:../HTMLFiles/normal_42.gif]](../HTMLFiles/normal_42.gif) 
  
Created by Mathematica (October 2, 2003)