1. Introduction

In this project, possible associated variables with the number of sold houses between the \(1^{st}\) of January 2007 and the \(30^{th}\) of June 2016 on the Stirling Ackroyd real estate company were analysed.

In this report the index Fixed 5Y Interest Rate will be explored and investigated. Enjoy the stability of knowing your repayments which won’t change for five years. This provides you with the stability of a normal fixed rate mortgage but doesn’t pin you down for such a long period of time that you get locked into an agreement with no way of taking advantage of favourable market fluctuations.

It might be interesting to compare this report with the Fixed 2Y Interest Rate

2. Data Manipulation

The data used in this report were taken from Quandl Fincancial and Economic Data. The file has 2 columns and 115 observations. As described above, the original data were manipulated and reduced to 114 observations (to match the time of interest) and a column containing only the year of the observation was added. In this report it will only be considered the closing value of the index.

3. Analysis

The dataset were summarized and some results can be seen below:

##    Min. 1st Qu.  Median    Mean 3rd Qu.    Max. 
##   2.570   3.418   4.295   4.466   5.555   6.400

The Box Plot is a exploratory graphic used to show the distribution of a dataset. In the present dataset the biggest value is 6.4 , 25% of data is greater than 5.555, 50% of data is greater than 4.295 (median value) and the smallest value is 2.57. The standard deviation is 1.1507348 and the amplitude is 3.83. It is of interest to analise how the variable behaves along time, as it can be seen in the plot below.

When compared with the Fixed 2Y Interest Rate the 5Y rate seems that has not suffered that much with the 2008/09 crisis. The series has a negative tendency and seems to present some seasonality.

In the analysis of time series it is comum that the observations are correlated among time,this characteristic is called autocorrelation. The Durbin-Watson test is a popular option to check the hypothesis of autocorrelation. In a confidence level of 95% the output of the test is a value (p-value) between 0 and 1: if (p-value \(>\) 0,05) the null hypothesis of non-autocorrelation is not rejected, otherwise (p-valor \(\leq\) 0.05) we assume that the observations of the series are correlated among time. Also, the autocorrelation function (ACF) tests the significance of the coeficiente among time (lags). The p-value is smaller than 0,05, so we assume that autocorrelation is significant.

## 
##  Durbin-Watson test
## 
## data:  base_index ~ base_date
## DW = 0.22187, p-value < 2.2e-16
## alternative hypothesis: true autocorrelation is greater than 0

Something algo very important in the analysis of time series is to check if the series has a stationary behavior or not. The test used in this report is the Dickey-Fuller test. Stationarity is one way of modeling the dependence structure. It turns out that a lot of nice results which holds for independent random variables hold for stationary random variables. And of course it turns out that a lot of data can be considered stationary, so the concept of stationarity is very important in modeling non-independent data.

The Dickey-Fuller test for this case presents p-value of 0.01. So, in a 5% level of significance, the series is stationary

To observe and compare the variation among the years of the Fixed 5Y Interest Rate the plot below shows a BoxPlot for the index in each year separately.

The boxes from 2009, 2010 and 2011 are clearly asymmetric with left tail, which means that 50% of the values in those years are concentrated in the upper part of the box and the other 50% has a big variation below the median line. The boxes tend to establish among the years.

As explained in section 1, the aim of the report is to verify the relationship between the Fixed 5Y Interest Rate index and the Number of Sold Houses on the Stirling Ackroyd real estate company. The first exploratory analysis is to check the Pearson Correlation between the two variables, as shown below.

## 
##  Pearson's product-moment correlation
## 
## data:  base_index and house.sold$numSoldHouses
## t = 5.8339, df = 112, p-value = 5.341e-08
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  0.3279641 0.6123099
## sample estimates:
##       cor 
## 0.4827601

It can be seen that the biggest values are very influential and they are from the years of 2007 to 2009

In the output there are two main informations: the correlation coefficient (0.4827601) and the p-value (5.340732810^{-8}). The correlation coefficient (CC) can be interpreted as a measure of the degree of linear relationship between two variables and the p-value is a test to check the CC is significant: if (p-value \(>\) 0,05) the null hypothesis of correlation equals to 0 is not rejected, otherwise (p-valor \(\leq\) 0.05) the correlation is significant. In this case, the linear relationship between the two variables is positive and moderate. As a complementary analysis, the plot shown above is a scatter plot between the variables and a regression line.

A point that has to be considered is that the data from the two variables are from quite a long time (9 years) and economic changes can be notice in short periods of time. Taking this into account the correlation coefficient will be analized considering different periods of time: i) the last 5 years and ii) the last 3 years. The output from the correlation test and coeficiente can be seen below and right beneath that a scatter plot is displayed, aiming to observe the existence of linear relationship.

i) Last 5 years

## 
##  Pearson's product-moment correlation
## 
## data:  base.5[, names(base.5) == variavel[2]] and house.sold.5$numSoldHouses
## t = -2.9753, df = 58, p-value = 0.004261
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.5655622 -0.1211684
## sample estimates:
##        cor 
## -0.3638968

The correlation coefficient is significant , in a 95% confidence level, when only the 5 last years are considered (p-value = 0.0042614), so there is significant linear relationship between the two variables.

When the data is filtered, big values from the X variables are excluded and the linear relationship becomes negative

ii) Last 3 years

## 
##  Pearson's product-moment correlation
## 
## data:  base.3[, names(base.3) == variavel[2]] and house.sold.3$numSoldHouses
## t = -4.2862, df = 34, p-value = 0.0001416
## alternative hypothesis: true correlation is not equal to 0
## 95 percent confidence interval:
##  -0.7708222 -0.3274584
## sample estimates:
##       cor 
## -0.592276

Using only the last 3 years, the correlation coefficient is significant and the linear relationship between the variables is negative and moderate. It can be seen that the variation in the values of the X variable is considerably smaller when only the 3 last years are included in the analysis