In: Statistics and Probability
An agent for a real estate company wanted to predict the monthly rent for apartments based on the size of the apartment. The data for a sample of 25 apartments is available below. Perform a t test for the slope to determine if a significant linear relationship between the size and the rent exists.
a. At the 0.05 level of significance, is there evidence of a linear relationship between the size of the apartment and the monthly rent?
b. Construct a 95% confidence interval estimate of the population slope,
betaβ1.
Size_(sq._ft)   Rent_($)
850   1950
1450   2575
1075   2200
1242   2525
728   1925
1495   2700
1146   2650
736   1935
700   1850
946   2175
1110   2375
1275   2625
1975   3300
1359   2825
1165   2400
1215   2475
1245   2100
1249   2675
1150   2200
896   2150
1361   2575
1040   2650
745   2200
990   1825
1210   2750
A. Find TSTAT
B. Find P-Value
C. 95% confidence interval is _
| ΣX | ΣY | Σ(x-x̅)² | Σ(y-ȳ)² | Σ(x-x̅)(y-ȳ) | |
| total sum | 28353 | 59610 | 1979590.64 | 3132016.0 | 2127641.80 | 
| mean | 1134.12 | 2384.40 | SSxx | SSyy | SSxy | 
sample size ,   n =   25  
       
here, x̅ = Σx / n=   1134.12   ,
    ȳ = Σy/n =  
2384.40  
          
       
SSxx =    Σ(x-x̅)² =   
1979590.6400      
   
SSxy=   Σ(x-x̅)(y-ȳ) =   2127641.8  
       
          
       
estimated slope , ß1 = SSxy/SSxx =  
2127641.8   /   1979590.640  
=   1.0748
          
       
intercept,   ß0 = y̅-ß1* x̄ =  
1165.4606          
          
       
so, regression line is   Ŷ =  
1165.4606   +   1.0748   *x
SSE=   (SSxx * SSyy - SS²xy)/SSxx =   
845250.475
      
std error ,Se =    √(SSE/(n-2)) =   
191.703
............................
a)
slope hypothesis test      
        tail=   2
Ho:   ß1=   0      
   
H1:   ß1╪   0      
   
n=   25          
   
alpha =   0.05      
       
estimated std error of slope =Se(ß1) = Se/√Sxx =   
191.703   /√   1979590.64  
=   0.1363
          
       
t stat = estimated slope/std error =ß1 /Se(ß1) =
   1.0748   /   0.1363  
=   7.8883
          
          
Degree of freedom ,df = n-2=   23  
           
p-value =    0.0000  
       
   
decison :    p-value<α , reject Ho  
           
reject Ho and conclude  that linear relations exists
between X and y
...................
b)
α=   0.05      
       
t critical value=   t α/2 =   
2.069   [excel function: =t.inv.2t(α/2,df) ]  
   
estimated std error of slope = Se/√Sxx =   
191.70295   /√   1979590.64  
=   0.136
          
       
margin of error ,E= t*std error =    2.069  
*   0.136   =   0.282
estimated slope , ß^ =    1.0748  
           
          
       
          
       
lower confidence limit = estimated slope - margin of error
=   1.0748   -   0.282  
=   0.7929
upper confidence limit=estimated slope + margin of error
=   1.0748   +   0.282  
=   1.3566
CI(0.7929 , 1.3566)
..........................
Please revert back in case of any doubt.
Please upvote. Thanks in advance.