Linear estimation with indicator variable

For technical questions regarding estimation of single equations, systems, VARs, Factor analysis and State Space Models in EViews. General econometric questions and advice should go in the Econometric Discussions forum.

Moderators: EViews Gareth, EViews Moderator

igtrader02
Posts: 3
Joined: Tue Jun 16, 2015 10:55 am

Linear estimation with indicator variable

Postby igtrader02 » Tue Jun 16, 2015 7:11 pm

Hi,

Can someone provide me with some guidance on how I should estimate a simple linear regression with an indicator variable?

Specifically, I am trying to estimate a linear regression that regresses selling price (SPRICE) on living area (LIVAREA)^2 but separating small houses from large houses using an indicator variable (LGELOT) which has the value of 1 for large lots and 0 for small lots. So essentially I should end up with an expression for that estimates the mean selling price for large lots and mean selling price for small lots and their associated coefficients for (LIVAREA)^2

I am using EViews 8 and just can't seem to obtain the answer. I've attached the EViews workfile.
stockton4.wf1
(104.42 KiB) Downloaded 200 times

startz
Non-normality and collinearity are NOT problems!
Posts: 3798
Joined: Wed Sep 17, 2008 2:25 pm

Re: Linear estimation with indicator variable

Postby startz » Tue Jun 16, 2015 9:39 pm

Hi,

Can someone provide me with some guidance on how I should estimate a simple linear regression with an indicator variable?

Specifically, I am trying to estimate a linear regression that regresses selling price (SPRICE) on living area (LIVAREA)^2 but separating small houses from large houses using an indicator variable (LGELOT) which has the value of 1 for large lots and 0 for small lots. So essentially I should end up with an expression for that estimates the mean selling price for large lots and mean selling price for small lots and their associated coefficients for (LIVAREA)^2

I am using EViews 8 and just can't seem to obtain the answer. I've attached the EViews workfile.
stockton4.wf1
Something like

Code: Select all

ls sprice c livarea^2 lgelot lgelot*livearea^2

igtrader02
Posts: 3
Joined: Tue Jun 16, 2015 10:55 am

Re: Linear estimation with indicator variable

Postby igtrader02 » Tue Jun 16, 2015 9:54 pm

.
Last edited by igtrader02 on Tue Jun 16, 2015 10:01 pm, edited 1 time in total.

startz
Non-normality and collinearity are NOT problems!
Posts: 3798
Joined: Wed Sep 17, 2008 2:25 pm

Re: Linear estimation with indicator variable

Postby startz » Tue Jun 16, 2015 9:57 pm

Hi,

Can someone provide me with some guidance on how I should estimate a simple linear regression with an indicator variable?

Specifically, I am trying to estimate a linear regression that regresses selling price (SPRICE) on living area (LIVAREA)^2 but separating small houses from large houses using an indicator variable (LGELOT) which has the value of 1 for large lots and 0 for small lots. So essentially I should end up with an expression for that estimates the mean selling price for large lots and mean selling price for small lots and their associated coefficients for (LIVAREA)^2

I am using EViews 8 and just can't seem to obtain the answer. I've attached the EViews workfile.
stockton4.wf1
Something like

Code: Select all

ls sprice c livarea^2 lgelot lgelot*livearea^2
Hi,

I've tried the command above already in my numerous attempts, but it does not yield the correct answer.

The answer according to the book is,

Large lots : SPRICE = 113279 + 193.83 * LIVAREA^2
Small lots : SPRICE = 62172 + 186.86 * LIVAREA^2

Can't seem to replicate the results.
So what do you get?

igtrader02
Posts: 3
Joined: Tue Jun 16, 2015 10:55 am

Re: Linear estimation with indicator variable

Postby igtrader02 » Tue Jun 16, 2015 9:58 pm

Just figured out how to do it.

Thanks y'all.


Return to “Estimation”

Who is online

Users browsing this forum: No registered users and 2 guests