Project – Deliverable 2 Harvard Case Solution & Analysis

Cleaning & Processing of Raw Data Set

 

In deliverable 1 of this project, we have identified a number of the issues with the data set. The first issues related to the presence of the unusual values or called as outliers in the data set. The interquartile range had been calculated and based on the lower fence and the upper fence intervals we have identified a number of variables where the outliers were present including the dependent variable which is the rate of crime in small US cities represented by Y. All those variables which had outliers in their data are Y, X1, X2, X5 and X6. If we compare the lower and the upper fence with the raw data as present in the data set file, then we can identify all the outliers which are out of the lower and the upper fence for each variable.

Therefore, first thing we did is to clean the entire data set and remove all the outliers to create a new trimmed data set. The trimming of the data set and the removal of all the lower and higher value outliers has been done through Winsorization. Winsorization is the transformation of the statistical data sets by limiting the extreme values within the data set in order to reduce the effect of the spurious outliers for performing the exploratory analysis in deliverable 3 of the project. In Winsorization all the high extreme values have been replaced by the upper bound value of that particular variable and the lower extreme values have been replaced by the lower bound value. The trimmed data set could be seen in the excel spreadsheet. The comparison of the means and the standard deviation for all the variables between raw data set and trimmed data set is shown in exhibit 1 in the appendix. Specifically the standard deviations show the effect of the removal of outliers from the data set. The trimmed data set could now be checked for extreme values by looking at lower and upper bounds as shown in exhibit 2 in the appendix.

Another important assumption for performing the exploratory analysis such as regression analysis is that the dependent variable should be normally distributed. This assumption has been tested and the normal curve in exhibit 2 in appendix shows that the dependent variable is normally distributed. Therefore, this shows that the Y variable could be used as an independent variable in our further exploratory analysis such as multiple regression analysis. It should be noted that the mean of the normal curve has decreased and the standard deviation for the normal curve has also decreased. This shows that the dependent variable data is now more accurately distributed as seen by the normal curve in exhibit 3 in the appendix.

Finally, we have also identified certain data entry issues with respect to the dependent variable which is crime rate. The previous histogram based on the raw data set showed a rightly skewed histogram which meant that the mean was greater than the median of the dependent variable. The right skewed distribution of the dependent variable would have distorted the results of regression analysis. This might have also been due to the presence of the outliers in the data set. The new histogram for the dependent variable Y based on the trimmed data set shows that the histogram is normally distributed now as the curve shows exactly a bell shaped curve. This shows that the effects of extreme values have been cleaned in the data set and points occurring on one side of the mean are similar as on the other side. The histogram could be seen in exhibit 4 in appendix. The data has been processed; the descriptive statistics and the final data set for performing the exploratory analysis could be seen in the data file.

 

 

Appendix

Exhibit 1: Trimmed Data Set Means

 

RAW DATA VS TRIMMED DATA SET
YX1X2X3X4X5X6
Mean (Raw Data)682.65568.2136.8558.1615.3328.6413.98
Mean (Trimmed Data)667.57542.7735.9558.1615.3327.8013.77
Stdev (Raw Data)219.38425.2710.138.194.5910.923.88
Stdev (Trimmed Data)166.99301.686.998.194.597.933.06

 

Exhibit 2: Checking Outliers

 

OUTLIERS IN DATA (Check with Trimmed Data)
YX1X2X3X4X5X6
Quartile 1546.75325.753151.75122312
Quartile 3776723.254065183216
Interquartile Range229.25397.5913.25694
Upper Bound1119.8751319.553.584.8752745.522
Lower Bound202.875-270.517.531.87539.56
OutliersDoes Not ExistDoes not ExistDoes not ExistDoes not ExistDoes not ExistDoes not ExistDoes not Exist

Exhibit 3: Normal Distribution Curve

Exhibit 4: Dependent Variable Histogram

Other Similar Case Solutions like

Project – Deliverable 2

Share This