P (A or B) = P (A) + P (B) − P (A and B)
P(A and B) = P(A) × P(B)
P(MR) ** 2 * P(FL)
P (A|B) = P (A and B) / P(B) **or** P(A and B) = P(A|B) × P(B)
For z-score
In [3]:
%%R
mean = 1500
sd = 300
d = 1800
(d-mean)/sd
To calculate the percentiles
In [9]:
%%R
mean = 1500
sd = 300
point = 2100
LT = T
pnorm(point,mean=mean,sd=sd,lower.tail=LT)
In [11]:
%%R
mean = 1500
sd = 300
percentile = 0.4
LT = T
qnorm(percentile,mean=mean,sd=sd,lower.tail=LT)
In [30]:
%%R
mean = 70
sd = 3.3
lower = 69
upper = 74
LT = T
# IN RANGE
# 1 - pnorm(upper,mean=mean,sd=sd,lower.tail=!LT) - pnorm(lower,mean=mean,sd=sd,lower.tail=LT)
# OUT RANGE
# pnorm(upper,mean=mean,sd=sd,lower.tail=!LT) + pnorm(lower,mean=mean,sd=sd,lower.tail=LT)
In [ ]: