log type: smcl
opened on: 30 Jan 2019, 23:24:04
. use "/Users/br2.dta"
. summarize price sqft
Variable | Obs Mean Std. Dev. Min Max
-------------+---------------------------------------------------------
price | 1,080 154863.2 122912.8 22000 1580000
sqft | 1,080 2325.938 1008.098 662 7897
. correlate price sqft
(obs=1,080)
| price sqft
-------------+------------------
price | 1.0000
sqft | 0.7607 1.0000
. correlate price sqft, covariance
(obs=1,080)
| price sqft
-------------+------------------
price | 1.5e+10
sqft | 9.4e+07 1.0e+06
. regress price sqft
Source | SS df MS Number of obs = 1,080
-------------+---------------------------------- F(1, 1078) = 1480.43
Model | 9.4326e+12 1 9.4326e+12 Prob > F = 0.0000
Residual | 6.8685e+12 1,078 6.3715e+09 R-squared = 0.5786
-------------+---------------------------------- Adj R-squared = 0.5783
Total | 1.6301e+13 1,079 1.5108e+10 Root MSE = 79822
------------------------------------------------------------------------------
price | Coef. Std. Err. t P>|t| [95% Conf. Interval]
-------------+----------------------------------------------------------------
sqft | 92.74737 2.410502 38.48 0.000 88.01757 97.47718
_cons | -60861.46 6110.187 -9.96 0.000 -72850.67 -48872.25
------------------------------------------------------------------------------
. predict yhat
(option xb assumed; fitted values)
. set obs 1081
number of observations (_N) was 1,080, now 1,081
. replace sqft = 3800 in 1081
(1 real change made)
. predict yhat1
(option xb assumed; fitted values)
. list sqft yhat1 in 1081
+-----------------+
| sqft yhat1 |
|-----------------|
1081. | 3800 291578.6 |
+-----------------+
. log close
log type: smcl
closed on: 30 Jan 2019, 23:27:13
2. Written assignment
Answer the following questions:
a. Is the data used in this exercise time-series data or cross-section data?
b. Is the data used in this exercise micro data or macro data?
c. What is the average sale price of a house in the sample? What is the average size of a
house in the sample? What are the estimated covariance and correlation coefficients
between Price and Sqft? What do the covariance and correlation coefficients suggest
about the relationship between the sale price of a house and its size?
d. Report (in equation format) the estimated regression obtained above by applying the
Stata software (Do not copy and paste the regression output table from Stata).
e. What are the values of the estimated slope coefficient and the estimated intercept
coefficient?
f. Interpret the estimated slope coefficient.
g. Is the sign of the estimated slope coefficient consistent with your expectations about
the relationship between the sale price of a house and its size?
h. Is the estimated intercept coefficient a meaningful estimate? Why or why not?
Answer 2 (a) : The data used in this exercise is a cross-section data. As can be seen here, the cross-section data involves a statistical data or collected information from various subjects or platforms either in a definite point of time or time spreading in to various points. As can be seen here, the data involves data of price and its corresponding square feet where the price in accordance to the square feet measurement is not in a series of equivalent time intervals.
Answer 2 (b) : The Data used in this exercise is a micro level data. A micro data involves the statistical data of the individual sector firm or of a person or per sector data. We can see here that the data in this exercise shows us the price per square feet of data.
Answer 2 ( c) : The average sale price of a house in this sample is = Mean price / mean square feet
= 154863.2/ 2325.938
= $ 66.58
The average size of a house in this sample is given as 2325.938 square feet.
The estimated covariance between price and Sqft is 1.0e+06 whereas the estimated correlation coefficient is sqft 9.4e+07 against price 1.5e+10
The estimated covariance and correlation between the sale price and the size of a house suggests that the price in correlation to the size of the house is not in a risky state. This is because a positive covariant and correlation coefficient indicate that the price of the definitive size of the house is in positive state in the market and does not have risks.
Answer 2 (h) : The estimated intercept coefficient is meaningful when the value of the constant x Is NIL or Zero (0) . In such a scenario, the intercept is only the mean or the average value of the coefficient. Therefore, here, the intercept coefficient does not hold too much of a meaning.
log type: smcl opened on: 30 Jan 2019, 23:24:04 . use "/Users/br2.dta" . summarize price sqft...
2. Use the data in hpricel.wfl uploaded on Moodle for this exercise. We assume that all assump- tions of the Classical Linear Model are satisfied for the model used in this question. (a) Estimate the model and report the results in the usual form, including the standard error of the regression. Obtain the predicted price when we plug in lotsize - 10, 000, sqrft - 2,300, and bdrms- 4; round this price to the nearest dollar. (b) Run a regression...
23:01 4G Midterm Econometrics II Semester 1 2.. 1 You are given data on price and quality of cocaine. You believe that the quality of cocaine affects the price, so you ran the following regression: The STATA output storage display valuc name type foemat l label variable label flat %9.0g float %9.0g float %9.0g float %9.0g peice per gram in dollars foe a cocaine number of grams of cocaine in a give quality of the cocaine expressed as a time...