Professional Documents
Culture Documents
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Brian Caffo
Department of Biostatistics
Johns Hopkins Bloomberg School of Public Health
Johns Hopkins University
August 3, 2012
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Table of contents
1 Table of contents
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
2 Random vectors
3 Independence
Independent events
Independent random variables
IID random variables
4 Correlation
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
8 Some discussion
Some
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Random vectors
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
PP
RR
f (x, y )dxdy = 1
f (x, y ) = 1
f (x, y ) = f (x)g (y )
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Independent events
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
P(A B) = P(A)P(B)
Two random variables, X and Y are independent if for any two sets A and B
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Example
Brian Caffo
Table of
contents
Random
vectors
Independence
A = {Head on flip 1}
P(A) = .5
B = {Head on flip 2}
P(B) = .5
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Example
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Volume 309 of Science reports on a physician who was on trial for expert
8, 543, Dr Meadow testified that that the probability of a mother having two
2
1
children with SIDS was 8,543
The mother on trial was convicted of murder
What was Dr Meadows mistake(s)?
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Example: continued
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
For the purposes of this class, the principal mistake was to assume that the
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Useful fact
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
f (x1 , . . . , xn ) =
n
Y
i=1
fi (xi )
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Example
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Suppose that we flip a biased coin with success probability p n times, what is
f (x1 , . . . , xn ) =
n
Y
i=1
p xi (1 p)1xi = p
xi
(1 p)n
xi
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Correlation
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Correlation
Brian Caffo
Table of
contents
Random
vectors
Cor(X , Y ) = Cov(X , Y )/
p
Var(X )Var(y )
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
1 Cor(X , Y ) 1
Cor(X , Y ) = 1 if and only if X = a + bY for some constants a and b
Cor(X , Y ) is unitless
4 X and Y are uncorrelated if Cor(X , Y ) = 0
5 X and Y are more positively correlated, the closer Cor(X , Y ) is to 1
6 X and Y are more negatively correlated, the closer Cor(X , Y ) is to 1
1
2
3
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Otherwise
Var
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
i=1
n
X
!
ai Xi + b
i=1
n
X
i=1
ai2 Var(Xi ) + 2
n1 X
n
X
ai aj Cov(Xi , Xj )
i=1 j=i
) = 2 /n and E [S 2 ] = 2
If the Xi are iid with variance 2 then Var(X
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Example proof
Prove that Var(X + Y ) = Var(X ) + Var(Y ) + 2Cov(X , Y )
Brian Caffo
Var(X + Y )
Table of
contents
Random
vectors
= E [(X + Y )(X + Y )] E [X + Y ]2
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
= E [X 2 + 2XY + Y 2 ] (x + y )2
= E [X 2 + 2XY + Y 2 ] 2x 2x y 2y
= (E [X 2 ] 2x ) + (E [Y 2 ] 2y ) + 2(E [XY ] x y )
= Var(X ) + Var(Y ) + 2Cov(X , Y )
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Result
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
random variables {Xi } are uncorrelated, then the variance of the sum is the
sum of the variances
!
n
n
X
X
Var
Xi =
Var(Xi )
i=1
i=1
deviations; that is, the standard deviation of the sum of bunch of independent
random variables is the square root of the sum of the variances, not the sum
of the standard deviations
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
Table of
contents
) = Var
Var(X
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Some
n
X
1
Var
Xi
n2
i=1
1
n2
n
X
Var(Xi )
i=1
1
n 2
n2
2
n
Variances
properties of
sample means
The sample
variance
i=1
Random
vectors
Independence
1X
Xi
n
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Some comments
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
) =
When Xi are independent with a common variance Var(X
n
The standard error of the sample mean is the standard deviation of the
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
Table of
contents
S =
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Variance and
correlation
properties
The sample
variance
Some
)2
X
n1
i=1 (Xi
Correlation
Variances
properties of
sample means
Pn
i=1
i=1
The sample variance is (nearly) the mean of the squared deviations from the
mean
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
"
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
n
X
#
)2
(Xi X
i=1
n
X
2
E Xi2 nE X
i=1
n
X
) + 2
Var(Xi ) + 2 n Var(X
i=1
n
X
2 + 2 n 2 /n + 2
i=1
= n 2 + n2 2 n2
Variances
properties of
sample means
The sample
variance
Some
= (n 1) 2
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Brian Caffo
Table of
contents
Random
vectors
Independence
S 2 estimates 2
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
Mathematical
Biostatistics
Boot Camp:
Lecture 4,
Random
Vectors
Example
Brian Caffo
Table of
contents
Random
vectors
Independence
Independent
events
Independent
random variables
IID random
variables
Correlation
Variance and
correlation
properties
Variances
properties of
sample means
The sample
variance
Some
p
(662361978 495 1151.2812 )/494 = 112.6215