part 22: multiple regression – part 2 22-1/60 statistics and data analysis professor william...
TRANSCRIPT
Part 22: Multiple Regression – Part 222-1/60
Statistics and Data Analysis
Professor William Greene
Stern School of Business
IOMS Department
Department of Economics
Part 22: Multiple Regression – Part 222-2/60
Statistics and Data Analysis
Part 22 – Multiple Regression: 2
Part 22: Multiple Regression – Part 222-3/60
Multiple Regression Models
Using Minitab To Compute A Multiple Regression Basic Multiple Regression Using Binary Variables Logs and Elasticities Trends in Time Series Data Using Quadratic Terms to Improve the Model Mini-seminar: Cost benefit test with a dynamic
model
Part 22: Multiple Regression – Part 222-4/60
Application: WHO
Data Used in Assignment 1: WHO data on 191 countries in 1995-1999. Analysis of Disability Adjusted Life Expectancy = DALE EDUC = average years of education PCHexp = Per capita health expenditure
DALE = α + β1EDUC + β2HealthExp + ε
Part 22: Multiple Regression – Part 222-5/60
The (Famous) WHO Data
Part 22: Multiple Regression – Part 222-6/60
Part 22: Multiple Regression – Part 222-7/60
Specify the Variables in the Model
Part 22: Multiple Regression – Part 222-8/60
Part 22: Multiple Regression – Part 222-9/60
Graphs
Part 22: Multiple Regression – Part 222-10/60
Regression Results
Part 22: Multiple Regression – Part 222-11/60
Practical Model Building
Understanding the regression: The left out variable problem
Using different kinds of variables Dummy variables Logs Time trend Quadratic
Part 22: Multiple Regression – Part 222-12/60
A Fundamental Result What happens when you leave a crucial
variable out of your model? Nothing good.
Regression Analysis: g versus GasPrice (no income)The regression equation isg = 3.50 + 0.0280 GasPricePredictor Coef SE Coef T PConstant 3.4963 0.1678 20.84 0.000GasPrice 0.028034 0.002809 9.98 0.000Regression Analysis: G versus GasPrice, Income The regression equation isG = 0.134 - 0.00163 GasPrice + 0.000026 IncomePredictor Coef SE Coef T PConstant 0.13449 0.02081 6.46 0.000GasPrice -0.0016281 0.0004152 -3.92 0.000Income 0.00002634 0.00000231 11.43 0.000
Part 22: Multiple Regression – Part 222-13/60
Using Dummy Variables Dummy variable = binary variable
= a variable that takes values 0 and 1. E.g. OECD Life Expectancies compared
to the rest of the world: DALE = α + β1 EDUC + β2 PCHexp
+ β3 OECD + ε
Australia, Austria, Belgium, Canada, Czech Republic, Denmark, Finland, France, Germany, Greece, Hungary, Iceland, Ireland, Italy, Japan, Korea, Luxembourg, Mexico, The Netherlands, New Zealand, Norway, Poland, Portugal, Slovak Republic, Spain, Sweden, Switzerland, Turkey, United Kingdom, United States.
Part 22: Multiple Regression – Part 222-14/60
OECD Life Expectancy
According to these results, after accounting for education and health expenditure differences, people in the OECD countries have a life expectancy that is 1.191 years shorter than people in other countries.
Part 22: Multiple Regression – Part 222-15/60
A Binary Variable in Regression
We set PCHExp to 1000, approximately the sample mean.
The regression shifts down by 1.191 years for the OECD countries
Part 22: Multiple Regression – Part 222-16/60
Academic Reputation
Part 22: Multiple Regression – Part 222-17/60
Part 22: Multiple Regression – Part 222-18/60
Part 22: Multiple Regression – Part 222-19/60
Part 22: Multiple Regression – Part 222-20/60
Part 22: Multiple Regression – Part 222-21/60
Part 22: Multiple Regression – Part 222-22/60
Dummy Variable in a Log Regression
E.g., Monet’s signature equation
Log$Price = α + β1 logArea + β2 Signed
Unsigned: PriceU = exp(α) Areaβ1
Signed: PriceS = exp(α) Areaβ1 exp(β2)
Signed/Unsigned = exp(β2)
%Difference = 100%(Signed-Unsigned)/Unsigned
= 100%[exp(β2) – 1]
Part 22: Multiple Regression – Part 222-23/60
The Signature Effect: 253%
100%[exp(1.2618) – 1] = 100%[3.532 – 1] = 253.2 %
Part 22: Multiple Regression – Part 222-24/60
Monet Paintings in Millions
Square Inches
Price
70006000500040003000200010000
30
25
20
15
10
5
0
01
Signed
Scatterplot of Price vs Square Inches
Predicted Price is exp(4.122+1.3458*logArea+1.2618*Signed) / 1000000
Difference is about 253%
Part 22: Multiple Regression – Part 222-25/60
Logs in Regression
Part 22: Multiple Regression – Part 222-26/60
Elasticity
The coefficient on log(Area) is 1.346 For each 1% increase in area, price goes up by
1.346% - even accounting for the signature effect. The elasticity is +1.346 Remarkable. Not only does price increase with
area, it increases much faster than area.
Part 22: Multiple Regression – Part 222-27/60
Monet: By the Square Inch
Area
price
70006000500040003000200010000
20000000
15000000
10000000
5000000
0
Scatterplot of Price vs Area
Part 22: Multiple Regression – Part 222-28/60
Logs and Elasticities
Theory: When the variables are in logs:
change in logx = %change in x
log y = α + β1 log x1 + β2 log x2 + … βK log xK + ε
Elasticity = βk
Part 22: Multiple Regression – Part 222-29/60
Elasticities
Price elasticity = -0.02070 Income elasticity = +1.10318
Part 22: Multiple Regression – Part 222-30/60
A Set of Dummy Variables
Complete set of dummy variables divides the sample into groups.
Fit the regression with “group” effects. Need to drop one (any one) of the
variables to compute the regression. (Avoid the “dummy variable trap.”)
Part 22: Multiple Regression – Part 222-31/60
Rankings of 132 U.S.Liberal Arts CollegesReputation = α + β1Religious + β2GenderEcon + β3EconFac + β4North + β5South + β6Midwest + β7West + ε
Nancy Burnett: Journal of Economic Education, 1998
Part 22: Multiple Regression – Part 222-32/60
Minitab does not like this model.
Part 22: Multiple Regression – Part 222-33/60
Too many dummy variables If we use all four region dummies, a is redundant
Reputation = a + bn + … if north Reputation = a + bm + … if midwest Reputation = a + bs + … if south Reputation = a + bw + … if west
Only three are needed – so Minitab dropped west Reputation = a + bn + … if north Reputation = a + bm + … if midwest Reputation = a + bs + … if south Reputation = a + … if west
Why did it drop West and not one of the others? It doesn’t matter which one is dropped. Minitab picked the last.
Part 22: Multiple Regression – Part 222-34/60
Unordered Categorical Variables
House price data (fictitious)
Style 1 = Split levelStyle 2 = RanchStyle 3 = ColonialStyle 4 = Tudor
Use 3 dummy variables for this kind of data. (Not all 4)
Using variable STYLE in the model makes no sense. You could change the numbering scale any way you like. 1,2,3,4 are just labels.
Part 22: Multiple Regression – Part 222-35/60
Transform Style to Types
Part 22: Multiple Regression – Part 222-36/60
Part 22: Multiple Regression – Part 222-37/60
House Price Regression
Each of these is relative to a Split Level, since that is the omitted category. E.g., the price of a Ranch house is $74,369 less than a Split Level of the same size with the same number of bedrooms.
Part 22: Multiple Regression – Part 222-38/60
Better Specified House Price Model Using Logs
Part 22: Multiple Regression – Part 222-39/60
Time Trends in Regression
y = α + β1x + β2t + ε β2 is the year to year increase not explained by anything else.
log y = α + β1log x + β2t + ε (not log t, just t) 100β2 is the year to year % increase not explained by anything else.
Part 22: Multiple Regression – Part 222-40/60
Time Trend in Multiple Regression
After accounting for Income, the price and the price of new cars, per capita gasoline consumption falls by 1.25% per year. I.e., if income and the prices were unchanged, consumption would fall by 1.25%. Probably the effect of improved fuel efficiency
Part 22: Multiple Regression – Part 222-41/60
A Quadratic Income vs. Age Regression+----------------------------------------------------+| LHS=HHNINC Mean = .3520836 || Standard deviation = .1769083 || Model size Parameters = 3 || Degrees of freedom = 27323 || Residuals Sum of squares = 794.9667 || Standard error of e = .1705730 || Fit R-squared = .7040754E-01 |+----------------------------------------------------++--------+--------------+--+--------+|Variable| Coefficient | Mean of X|+--------+--------------+-----------+ Constant| -.39266196 AGE | .02458140 43.5256898 AGESQ | -.00027237 2022.85549 EDUC | .01994416 11.3206310+--------+--------------+-----------+
Note the coefficient on Age squared is negative. Age ranges from 25 to 65.
Part 22: Multiple Regression – Part 222-42/60
Implied By The Model
Careful: This shows the incomes of people of different ages, not the path of income of a particular person at different ages.
Part 22: Multiple Regression – Part 222-43/60
Candidate Models for CostThe quadratic equation is the appropriate model.
Logc = a + b1 logq + b2 log2q + e
Part 22: Multiple Regression – Part 222-44/60
A Better Model?
Log Cost = α + β1 logOutput + β2 [logOutput]2 + ε
Part 22: Multiple Regression – Part 222-45/60
Part 22: Multiple Regression – Part 222-46/60
Part 22: Multiple Regression – Part 222-47/60
Case Study Using A Regression Model: A Huge Sports Contract
Alex Rodriguez hired by the Texas Rangers for something like $25 million per year in 2000.
Costs – the salary plus and minus some fine tuning of the numbers
Benefits – more fans in the stands. How to determine if the benefits exceed the
costs? Use a regression model.
Part 22: Multiple Regression – Part 222-48/60
The Texas Deal for Alex Rodriguez
2001 Signing Bonus = 10M 2001 21 2002 21 2003 21 2004 21 2005 25 2006 25 2007 27 2008 27 2009 27 2010 27 Total: $252M ???
Part 22: Multiple Regression – Part 222-49/60
The Real Deal Year Salary Bonus Deferred Salary 2001 21 2 5 to 2011 2002 21 2 4 to 2012 2003 21 2 3 to 2013 2004 21 2 4 to 2014 2005 25 2 4 to 2015 2006 25 4 to 2016 2007 27 3 to 2017 2008 27 3 to 2018 2009 27 3 to 2019 2010 27 5 to 2020 Deferrals accrue interest of 3% per year.
Part 22: Multiple Regression – Part 222-50/60
Costs
Insurance: About 10% of the contract per year (Taxes: About 40% of the contract) Some additional costs in revenue sharing revenues from
the league (anticipated, about 17.5% of marginal benefits – uncertain)
Interest on deferred salary - $150,000 in first year, well over $1,000,000 in 2010.
(Reduction) $3M it would cost to have a different shortstop. (Nomar Garciaparra)
Part 22: Multiple Regression – Part 222-51/60
PDV of the Costs
Using 8% discount factor Accounting for all costs including insurance Roughly $21M to $28M in each year from
2001 to 2010, then the deferred payments from 2010 to 2020
Total costs: About $165 Million in 2001 (Present discounted value)
Part 22: Multiple Regression – Part 222-52/60
Benefits
More fans in the seats Gate Parking Merchandise
Increased chance at playoffs and world series Sponsorships (Loss to revenue sharing) Franchise value
Part 22: Multiple Regression – Part 222-53/60
How Many New Fans?
Projected 8 more wins per year. What is the relationship between wins
and attendance? Not known precisely Many empirical studies (The Journal of
Sports Economics) Use a regression model to find out.
Part 22: Multiple Regression – Part 222-54/60
Baseball Data 31 teams, 17 years (fewer years for 6 teams) Winning percentage: Wins = 162 * percentage Rank Average attendance. Attendance = 81*Average Average team salary Number of all stars Manager years of experience Percent of team that is rookies Lineup changes Mean player experience Dummy variable for change in manager
Part 22: Multiple Regression – Part 222-55/60
Baseball Data (Panel Data – 31 Teams, 17 Years)
Part 22: Multiple Regression – Part 222-56/60
A Regression Model
team
1
Attendance(team,this year) = α
+ γ Attendance(team, last year)
+ β Wins (team,this year)
2
3
+ β Wins(team, last year)
+ All_Stars(team, this year)
+ (team, this year)
Part 22: Multiple Regression – Part 222-57/60
Part 22: Multiple Regression – Part 222-58/60
A Dynamic Equationy(this year) = f[y(last year)…]
Fans(t)=a+bWins(t)+cFans(t-1)+ (Loyalty effect)
Suppose Fans(0) = Fans0 (Start observing in a base year)
Suppose we fix Wins(t) at some Wins* and at 0 (no information).
What values do
es Fans(t) take in a sequence of years?
Fans(1) = a + bWins* + cFans0
Fans(2) = a + bWins* + c(a + bWins* + cFans0)
Fans(3) = a + bWins* + c(a + bWins* + c(a + bWins* + cFans0))
Fans(4) = a + bWins* + c(a
2 t-1 2 t-1 t
+ bWins* + c(a + bWins* + c(a + bWins* + cFans0)))
etc.
Collect terms: Fans(t) = a(1+c+c ... c ) bWins*(1+c+c ... c )+c Fans0
Suppose 0 < c < 1.
a bFans finally settles down at Fans* = + Wi
1-c 1-c
b dFans*ns*. =
1-c dWins *
Part 22: Multiple Regression – Part 222-59/60
Example : Fans(t) = 227969+.6Fans(t-1) +11093Wins
Wins = 85/year
Fans(1990)=2,500,000
Fans(1991) = 227969 + .6(2.5M) + 11093(85) = 2.671M
Fans(1992) = ..... = 2.773M
...
Fans(2006) and years after = 2.93M
(This is the 'equilibrium')
Part 22: Multiple Regression – Part 222-60/60
Part 22: Multiple Regression – Part 222-61/60
Example : Fans(t) = 227969+.6Fans(t-1) +11093Wins
Wins = 85/year to 2000, 93/year 2001...
Fans(1990) = 2,500,000
Fans(1991) = 2.671M
Fans(1992 to 2000) about 2.9M
...
Fans(2001) and years after about 3.15M
(This is the 'equilibrium)
Part 22: Multiple Regression – Part 222-62/60
About 220,000 fans
Part 22: Multiple Regression – Part 222-63/60
Marginal Value of One More Win
1 2 3
1 2 3
Our Model is Fans(t) = α + β Wins(t) + β Wins(t-1) + β AllStars + γFans(t-1)
Using the formula for the value of Fans*
α+β Wins*+β Wins*+β AllStarsFans*=
1-γ
The effect of one more Win every year would be 1 2
3
dFans*/dWins* = 1
The new player will definitely be an All Star, so we add this effect as well.
The effect of adding an All Star player to the team would be 1
Part 22: Multiple Regression – Part 222-64/60
= .54914
1 = 11093.7
2 = 2201.2
3 = 14593.5
Effect of 1 more win
11093.7 2201.2= 32757
1 .59414Effect of adding an All Star
14593.5= 35957
1 .59414
Part 22: Multiple Regression – Part 222-65/60
Marginal Value of an A Rod (8 games * 32,757 fans) + 1 All Star = 35957
= 298,016 new fans 298,016 new fans *
$18 per ticket $2.50 parking etc. (Average. Most people don’t park) $1.80 stuff (hats, bobble head dolls,…)
$6.67 Million per year !!!!! It’s not close. (Marginal cost is at least $16.5M / year)
Part 22: Multiple Regression – Part 222-66/60
Summary Using Minitab To Compute a Regression Building a Model
Logs Dummy variables Qualitative variables Trends Effects across time Quadratic