Covariance and Correlation

Similar documents
f X, Y (x, y)dx (x), where f(x,y) is the joint pdf of X and Y. (x) dx

ENGG2430A-Homework 2

Statistics 351 Probability I Fall 2006 (200630) Final Exam Solutions. θ α β Γ(α)Γ(β) (uv)α 1 (v uv) β 1 exp v }

Problem #1 #2 #3 #4 Total Points /5 /7 /8 /4 /24

Summer School in Statistics for Astronomers V June 1 - June 6, Regression. Mosuk Chow Statistics Department Penn State University.

Variance reduction. Michel Bierlaire. Transport and Mobility Laboratory. Variance reduction p. 1/18

Chapter 4 continued. Chapter 4 sections

STAT/MATH 395 PROBABILITY II

18 Bivariate normal distribution I

Jointly Distributed Random Variables

ECE302 Exam 2 Version A April 21, You must show ALL of your work for full credit. Please leave fractions as fractions, but simplify them, etc.

Multivariate Random Variable

Ch. 5 Joint Probability Distributions and Random Samples

1 x 2 and 1 y 2. 0 otherwise. c) Estimate by eye the value of x for which F(x) = x + y 0 x 1 and 0 y 1. 0 otherwise

Lecture 16 : Independence, Covariance and Correlation of Discrete Random Variables

STA 256: Statistics and Probability I

Problem Set #6: OLS. Economics 835: Econometrics. Fall 2012

Random Signals and Systems. Chapter 3. Jitendra K Tugnait. Department of Electrical & Computer Engineering. Auburn University.

Final Exam. Economics 835: Econometrics. Fall 2010

Bivariate Distributions. Discrete Bivariate Distribution Example

Joint Gaussian Graphical Model Review Series I

5 Operations on Multiple Random Variables

Simple Linear Regression Estimation and Properties

Bivariate distributions

Raquel Prado. Name: Department of Applied Mathematics and Statistics AMS-131. Spring 2010

Econ 2120: Section 2

CHAPTER 5. Jointly Probability Mass Function for Two Discrete Distributed Random Variables:

Joint Probability Distributions

Class 8 Review Problems solutions, 18.05, Spring 2014

Scatter plot of data from the study. Linear Regression

Problem Solving. Correlation and Covariance. Yi Lu. Problem Solving. Yi Lu ECE 313 2/51

Linear Models and Estimation by Least Squares

Chapter 12 - Lecture 2 Inferences about regression coefficient

LIST OF FORMULAS FOR STK1100 AND STK1110

Simple Linear Regression

Vectors and Matrices Statistics with Vectors and Matrices

Properties of Summation Operator

MATHEMATICS 154, SPRING 2009 PROBABILITY THEORY Outline #11 (Tail-Sum Theorem, Conditional distribution and expectation)

Lecture 3 - Expectation, inequalities and laws of large numbers

Optimization and Simulation

Scatter plot of data from the study. Linear Regression

11. Regression and Least Squares

Conditional distributions. Conditional expectation and conditional variance with respect to a variable.

Class 8 Review Problems 18.05, Spring 2014

Joint Probability Distributions and Random Samples (Devore Chapter Five)

Introduction to Simple Linear Regression

1 Probability theory. 2 Random variables and probability theory.

Bivariate Distributions

Bivariate Paired Numerical Data

P (x). all other X j =x j. If X is a continuous random vector (see p.172), then the marginal distributions of X i are: f(x)dx 1 dx n

Lecture 4: Proofs for Expectation, Variance, and Covariance Formula

Chapter 5 continued. Chapter 5 sections

MA 575 Linear Models: Cedric E. Ginestet, Boston University Revision: Probability and Linear Algebra Week 1, Lecture 2

6.041/6.431 Fall 2010 Quiz 2 Solutions

ECE Lecture #9 Part 2 Overview

Multivariate probability distributions and linear regression

Matrix Approach to Simple Linear Regression: An Overview

Preliminary Statistics. Lecture 3: Probability Models and Distributions

Correlation 1. December 4, HMS, 2017, v1.1

Notes on Random Processes

Business Statistics 41000: Homework # 2 Solutions

For a stochastic process {Y t : t = 0, ±1, ±2, ±3, }, the mean function is defined by (2.2.1) ± 2..., γ t,

Statistics Examples. Cathal Ormond

Joint probability distributions: Discrete Variables. Two Discrete Random Variables. Example 1. Example 1

Fitting a regression model

STA 2201/442 Assignment 2

Lecture 22: Variance and Covariance

Continuous Random Variables

REVIEW OF MAIN CONCEPTS AND FORMULAS A B = Ā B. Pr(A B C) = Pr(A) Pr(A B C) =Pr(A) Pr(B A) Pr(C A B)

Linear models and their mathematical foundations: Simple linear regression

Problem Set #5. Econ 103. Solution: By the complement rule p(0) = 1 p q. q, 1 x 0 < 0 1 p, 0 x 0 < 1. Solution: E[X] = 1 q + 0 (1 p q) + p 1 = p q

ECON 3150/4150, Spring term Lecture 6

ECE 302: Probabilistic Methods in Engineering

Simple Linear Regression

matrix-free Elements of Probability Theory 1 Random Variables and Distributions Contents Elements of Probability Theory 2

Outline Properties of Covariance Quantifying Dependence Models for Joint Distributions Lab 4. Week 8 Jointly Distributed Random Variables Part II

More than one variable

Review of probability and statistics 1 / 31

variability of the model, represented by σ 2 and not accounted for by Xβ

Summary of basic probability theory Math 218, Mathematical Statistics D Joyce, Spring 2016

EECS 126 Probability and Random Processes University of California, Berkeley: Spring 2015 Abhay Parekh February 17, 2015.

Hypergeometric, Poisson & Joint Distributions

HW4 : Bivariate Distributions (1) Solutions

Ph.D. Qualifying Exam Friday Saturday, January 6 7, 2017

Quantitative Methods in Economics Conditional Expectations

Chapter 2. Some Basic Probability Concepts. 2.1 Experiments, Outcomes and Random Variables

Expectation and Variance

Final Exam # 3. Sta 230: Probability. December 16, 2012

Applied Regression. Applied Regression. Chapter 2 Simple Linear Regression. Hongcheng Li. April, 6, 2013

Functions of two random variables. Conditional pairs

Elements of Probability Theory

Multivariate Distributions CIVL 7012/8012

Estimating Estimable Functions of β. Copyright c 2012 Dan Nettleton (Iowa State University) Statistics / 17

Lecture 25: Review. Statistics 104. April 23, Colin Rundel

conditional cdf, conditional pdf, total probability theorem?

Week 3: Simple Linear Regression

Homework 5 Solutions

Lecture 2: Repetition of probability theory and statistics

MULTIVARIATE PROBABILITY DISTRIBUTIONS

Week 10 Worksheet. Math 4653, Section 001 Elementary Probability Fall Ice Breaker Question: Do you prefer waffles or pancakes?

Transcription:

Covariance and Correlation ST 370 The probability distribution of a random variable gives complete information about its behavior, but its mean and variance are useful summaries. Similarly, the joint probability distribution of two random variables gives complete information about their joint behavior, but their means and variances do not summarize how they behave together. We also need to know their covariance: cov(x, Y ) = σ XY = E [(X µ X ) (Y µ Y )]. 1 / 15 Joint Probability Distributions Covariance and Correlation

Example: Mobile response time x = Number of bars 1 2 3 Marginal y = Response time 4+ 0.15 0.10 0.05 0.30 3 0.02 0.10 0.05 0.17 2 0.02 0.03 0.20 0.25 1 0.01 0.02 0.25 0.28 Marginal 0.20 0.25 0.55 From the marginal distributions: µ X = 1 0.20 + 2 0.25 + 3 0.55 = 2.35, µ Y = 1 0.28 + 2 0.25 + 3 0.17 + 4 0.30 = 2.49. 2 / 15 Joint Probability Distributions Covariance and Correlation

Also from the marginal distributions, σ 2 X = 0.6275, σ 2 Y = 1.4099. For the covariance, we need the joint distribution: 3 4 σ XY = [(x µ X ) (y µ Y )] f XY (x, y) x=1 y=1 = 0.5815. 3 / 15 Joint Probability Distributions Covariance and Correlation

Sign of covariance Negative covariance, as here, means that X and Y tend to move in opposite directions: a stronger signal leads to shorter response times, and conversely. Positive covariance would mean that they tend to move in the same direction; zero covariance would mean that X and Y are not linearly related. 4 / 15 Joint Probability Distributions Covariance and Correlation

Magnitude of covariance The magnitude of the covariance is harder to interpret; in particular, it has the units of X multiplied by the units of Y, here seconds 2. It is easier to interpret a dimensionless quantity, the correlation coefficient ρ XY = cov(x, Y ) = σ XY. V (X )V (Y ) σ X σ Y The correlation coefficient has the same sign as the covariance, and always lies between 1 and +1; in the example, ρ XY = 0.618228. 5 / 15 Joint Probability Distributions Covariance and Correlation

Independence If X and Y are independent, then f XY (x, y) = f X (x) f Y (y), and E(XY ) = x = x = x xyf XY (x, y) y xyf X (x)f Y (y) y xf X (x) yf Y (y) y = E(X )E(Y ). 6 / 15 Joint Probability Distributions Covariance and Correlation

More generally, E[(X a)(y b)] = E(X a)e(y b) and with a = µ X and b = µ Y, cov(x, Y ) = E(X µ X )E(Y µ Y ) = 0, and consequently also ρ XY = 0. That is, if X and Y are independent, they are also uncorrelated. The opposite is not generally true: if X and Y are uncorrelated, they might or might not be independent. 7 / 15 Joint Probability Distributions Covariance and Correlation

Estimating covariance and correlation The covariance σ XY and correlation ρ XY are characteristics of the joint probability distribution of X and Y, like µ X, σ X, and so on. That is, they characterize the population of values of X and Y. 8 / 15 Joint Probability Distributions Covariance and Correlation

From a sample of values, we estimate µ X and σ X by x and s x, the sample mean and standard deviation. By analogy with the sample variance s 2 x = 1 n 1 the sample covariance is given by s xy = 1 n 1 n (x i x) 2, i=1 n (x i x)(y i ȳ). i=1 9 / 15 Joint Probability Distributions Covariance and Correlation

The sample correlation coefficient is r xy = s xy s x s y n i=1 = (x i x)(y i ȳ) n i=1 (x i x) 2 n i=1 (y i ȳ). 2 Notice the similarity to the calculation of the regression coefficient ˆβ 1 = n i=1 (x i x)(y i ȳ) n i=1 (x i x) 2 = s xy s 2 x = r xy s y s x. 10 / 15 Joint Probability Distributions Covariance and Correlation

But note the difference in context: In the regression context, we have a model Y = β 0 + β 1 x + ɛ, in which x is a fixed quantity, and Y is a random variable; In the correlation context, both X and Y are random variables. The connection between correlation and regression is deeper than just the computational similarity, but they are not the same thing. 11 / 15 Joint Probability Distributions Covariance and Correlation

Linear Functions of Random Variables ST 370 Given random variables X 1, X 2,..., X p and constants c 1, c 2,..., c p the random variable Y given by Y = c 1 X 1 + c 2 X 2 + + c p X p is a linear combination of X 1, X 2,..., X p. The expected value of Y is E(Y ) = c 1 E(X 1 ) + c 2 E(X 2 ) + + c p E(X p ) 12 / 15 Joint Probability Distributions Linear Functions of Random Variables

The variance of Y involves both the variances and covariances of the X s. If the X s are uncorrelated, and in particular if they are independent, then V (Y ) = c 2 1 V (X 1 ) + c 2 2 V (X 2 ) + + c 2 pv (X p ). 13 / 15 Joint Probability Distributions Linear Functions of Random Variables

Special case: the average If c 1 = c 2 = = c p = 1 p, then Y is just X, the average of X 1, X 2,..., X p If the X s all have the same expected value µ, then E ( X ) = µ and if they are uncorrelated and all have the same variance σ 2, then V ( X ) = σ2 p. 14 / 15 Joint Probability Distributions Linear Functions of Random Variables

Note that σ X = σ p, which becomes small when p is large. That means that when p is large, X is likely to be close to µ, a result known as the weak law of large numbers. 15 / 15 Joint Probability Distributions Linear Functions of Random Variables