Sales Value of Resdental Property y = b X D2 +b D3 +b A2 1 2 3 4 5 y = sales value of the property (dollars) X = square feet of lvng space D1=dummy vble for one bedroom home D2=dummy vble for two bedroom home D3=dummy vble for three bedroom home A1=dummy vble for one bathroom home A2=dummy vble for two bathroom home For a one-bedroom, one-bathroom home, such that D2=0, D3=0, and A2=0, we have: y = b 1 2 X 1 bedroom, 1 bathroom
sellng prce y b 1 +b 4 +b 5 b 1 +b 4 b 1 +b 3 +b 5 House Sales Model wth Restrcted Intercepts y = b 1 2 X 3 D2 4 D3 5 A2 D3-A2 (three bed, two bath) D3-A1 (three bed, one bath) D2-A2 (two bed, two bath) D2-A1 (two bed, one bath) D1-A2 (one bed, two bath) D1-A1 (one bed,one bath) b 1 +b 3 b 1 +b 5 b 2 b 1 0 X square feet of lvng space
Sales Value of Resdental Property y = b 1 2 X 3 D2 +b 4 D3 +b 5 A2 For a 2-bedroom, 1-bathroom home, we have D2=1, D3=0, and A2=0 y = (b 1 3 ) 2 X 2 bedroom, 1 bathroom
Sales Value of Resdental Property y = b 1 2 X 3 D2 4 D3 5 A2 For a 1-bedroom, 2-bathroom home, we have D2=0, D3=0, and A2=1 y = (b 1 5 ) 2 X 1 bedroom, 2 bathroom
Sales Value of Resdental Property y = b 1 2 X 3 D2 4 D3 5 A2 For a 2-bedroom, 2-bathroom home, we have D2=1, D3=0, and A2=1 y = (b 1 3 5 ) 2 X 2 bedroom, 2 bathroom y = (b 1 4 5 ) 2 X 3 bedroom, 2 bathroom y = (b 1 4 ) 2 X 3 bedroom, 1 bathroom
Sales Value of Resdental Property y = b 1 2 X 3 D2 4 D3 5 A2 y = sales value of the property (dollars) X = square feet of lvng space D1=dummy vble for one bedroom home D2=dummy vble for two bedroom home D3=dummy vble for three bedroom home A1=dummy vble for one bathroom home A2=dummy vble for two bathroom home D2A2 = nteracton two-bed & two-bath D3A2 = nteracton three-bed & two-bath y = β 1 + β 2 X + β 3 D2 + β 4 D3 + β 5 A2 + β 6 D2A2 + β 7 D3A2
Ths one equaton wth all these dummy varables actually s representng sx equatons. You must substtute n for each of the dummy varables n order to generate the sx equatons that are mpled by ths one dummy varable equaton. y = b 1 2 X 3 D2 4 D3 5 A2 6 D2A2 7 D3A2 For a one-bedroom, one-bathroom home, such that D2=0, D3=0, and A2=0, we have: y = b 1 2 X 1 bedroom, 1 bathroom
House Sales Model wth Unrestrcted Intercepts sellng prce y D3-A2 (three bed, two bath) D3-A1 (three bed, one bath) D2-A2 (two bed, two bath) D2-A1 (two bed, one bath) D1-A2 (one bed, two bath) D1-A1 (one bed,one bath) b 2 b 1 0 X square feet of lvng space
y = β 1 + β 2 X + β 3 D2 + β 4 D3 + β 5 A2 + β 6 D2A2 + β 7 D3A2 two-bedroom, one-bathroom D1=0, D2=1, D3=0 and A1=1, A2=0 y = (β 1 + β 3 ) + β 2 X 2 bedroom, 1 bathroom now graph t! =======>
House Sales Model wth Unrestrcted Intercepts sellng prce y D3-A2 (three bed, two bath) D3-A1 (three bed, one bath) D2-A2 (two bed, two bath) D2-A1 (two bed, one bath) D1-A2 (one bed, two bath) D1-A1 (one bed,one bath) b 1 +b 3 b 1 0 X square feet of lvng space
y = b 1 2 X 3 D2 4 D3 5 A2 6 D2A2 7 D3A2 one-bedroom, two-bathroom D1=1, D2=0, D3=0 and A1=0, A2=1 y = (b 1 5 ) 2 X 1 bedroom, 2 bathroom now graph t! =======>
House Sales Model wth Unrestrcted Intercepts sellng prce y D3-A2 (three bed, two bath) D3-A1 (three bed, one bath) D2-A2 (two bed, two bath) D2-A1 (two bed, one bath) D1-A2 (one bed, two bath) D1-A1 (one bed,one bath) b 1 +b 3 b 1 +b 5 b 1 0 X square feet of lvng space
y = b 1 2 X 3 D2 4 D3 5 A2 6 D2A2 7 D3A2 two-bedroom, two-bathroom D1=0, D2=1, D3=0 and A1=0, A2=1 y = (b 1 3 5 +b 6 ) +b 2 X 2 bedroom, 2 bathroom now graph t! =======>
House Sales Model wth Unrestrcted Intercepts sellng prce y b 1 +b 3 +b 5 +b 6 D3-A2 (three bed, two bath) D3-A1 (three bed, one bath) D2-A2 (two bed, two bath) D2-A1 (two bed, one bath) D1-A2 (one bed, two bath) D1-A1 (one bed,one bath) b 1 +b 3 b 1 +b 5 b 1 0 X square feet of lvng space
House Sales Model wth Unrestrcted Intercepts sellng prce y b 1 +b 4 +b 5 +b 7 b 1 +b 4 b 1 +b 3 +b 5 +b 6 D3-A2 (three bed, two bath) D3-A1 (three bed, one bath) D2-A2 (two bed, two bath) D2-A1 (two bed, one bath) D1-A2 (one bed, two bath) D1-A1 (one bed,one bath) b 1 +b 3 b 1 +b 5 b 1 0 X square feet of lvng space
How do we create composte dummy varables? Bathrooms Want to account for nteracton between race and gender. 1 2 Bedrooms 2 25 15 40 3 13 27 40 38 42 80
Garage vs. Bedrooms vs. Bathrooms Bedrooms 1 2 3 Baths: 1 2 1 2 1 2 Garage 0 2 4 3 5 10 16 40 1 1 6 0 7 12 14 40 3 10 3 12 22 30 80
Karnaugh Map for Garage, Bedrooms, Bathrooms, and School Dstrct: Bedrooms S C H O O L A B Baths: Garage 1 2 3 all 1 2 1 2 1 2 0 1 3 2 5 6 13 30 Garage 1 0 3 0 6 7 8 24 0 1 1 1 0 4 3 10 1 1 3 0 1 5 6 16 all 3 10 3 12 22 30 80
Composte dummy varables are created for each nonempty cell. Create four composte dummy varables: D1A1=1 f one bedroom, one bath; D1A2=1 f one bedroom, two bath; D2A1=1 f two bedroom, one bath; D2A2=1 f two bedroom, two bath;.
Testng effect of 2nd Bathroom on Sales Value: Y ˆ = b X S S X 1 2 3 5 H 0 : β 3 0 vs. H 1 : β 3 > 0 H 0 : β 5 0 vs. H 1 : β 5 > 0 b 3 Est. Varb 3 t n 4 b 5 Est. Var b 5 tn 4
Testng Ho: β3 = β5 = 0 H1 : otherwse (SSE R SSE U )/ 2 SSE U /(n 4) F 2 n 4 and n =1 SSE U = (y b 1 b 2 X b 3 S b 5 S X ) 2 n SSE R = (y b 1 b 2 X ) 2 = 1
Sale of House wth Bed and Bath Dummes PRICE = f ( SQFEET, D2BED, B3BED, A2BATH ) I. SQFEET = square feet of lvng space II. D2BED = dummy=1 f two-bedroom house III. D3BED = dummy=1 f three-bedroom house IV. A2BATH = dummy=1 f two-bathroom house I. II. III. IV. PRICE (thousands) 800 0 0 0 10.000 1000 0 0 1 20.000 1200 1 0 0 30.000 1500 1 0 0 40.000 1800 1 0 1 50.000 2000 1 0 1 60.000 2200 0 1 0 70.000 2500 0 1 0 80.000 3000 0 1 1 90.000 3500 0 1 1 100.000
Sale of House wth Bed and Bath Dummes PRICE = f ( SQFEET, D2BED, B3BED, A2BATH ) DEP VAR: PRICE N: 10 MULTIPLE R: 0.996 SQUARED MULTIPLE R: 0.993 ADJUSTED SQUARED MULTIPLE R: 0.987 STD ERROR OF ESTIMATE: 3.40 VARIABLE COEFF STD ERR T P(2-TAIL) INTERCEPT - 6.482 4.112-1.576 0.176 SQFEET 0.021 0.005 3.958 0.011 D2BED 14.662 4.871 3.010 0.030 D3BED 29.803 10.575 2.818 0.037 A2BATH 4.883 3.953 1.235 0.272 ( for 1,000 square feet: 21-6.482 = 14.518 or $14,518 )
Regresson Analyss of Sale of Resdental Property VARIABLE COEFF STD ERR T P(2-TAIL) INTERCEPT - 6.482 4.112-1.576 0.176 SQFEET 0.021 0.005 3.958 0.011 D2BED 14.662 4.871 3.010 0.030 D3BED 29.803 10.575 2.818 0.037 A2BATH 4.883 3.953 1.235 0.272 for 1,000 square feet: 21-6.482 = 14.518 or $14,518 add a bathroom: $14,518 4,883 $19,401 add a bedroom: $14,518 14,662 $29,180 add 2 bedrooms: $14,518 29,803 $44,321 add bath and 2 bedrooms: 14,518 + 4,883 + 29,803 = $49,204
Sale of House wth Bed and Bath Dummes PRICE = f ( SQFEET, D2BED, B3BED, A2BATH ) DEP VAR: PRICE N: 10 MULTIPLE R: 0.996 SQUARED MULTIPLE R: 0.993 ADJUSTED SQUARED MULTIPLE R: 0.987 STD ERROR OF ESTIMATE: 3.40 ANALYSIS OF VARIANCE SOURCE SUM-OF-SQUARES DF MEAN-SQ F-RATIO P REGRESSION 8191.943 4 2047.986 176.378 0.000 RESIDUAL 58.057 5 11.611 DURBIN-WATSON D STATISTIC: 2.216 FIRST ORDER AUTOCORRELATION COEFF: - 0.153
Plot of House Prce x Square Feet 150 bgger houses cost more! 100 PRICE 50 0 0 1000 2000 3000 4000 SQFEET
Plot of Orgnal Data Ponts SYSTAT GRAPH 150 100 50 0 800 1000 1200 1500 1800 2000 2200 2500 3000 3500 PRICE SQFEET
Plot Prce of 1 & 2 Bathroom Houses SYSTAT GRAPH thousand $ looks lke a fxed upward shft n prce! 150 100 PRICE 50 0-1 0 1 2 A2BATH