So, what went wrong? Why have our sophisticated models achieved nothing better than random chance? Is there a problem with our models?
Recall that we started out by just throwing the data at our model. In fact, we didn't even throw all our data at the model, just the numeric columns that were easy to use. Furthermore, we didn't do a lot of analysis on these numeric features.
Many models that we employ make inherent assumptions about the distribution or scale of input data. One of the most common forms of assumption is about normally-distributed features. Let's take a deeper look at the distribution of our features.
To do this, we can represent the feature vectors as a distributed matrix in MLlib, using the RowMatrix
class. RowMatrix
is an RDD made up of vector, where each vector is a row of our matrix.
The RowMatrix
class comes with some useful methods to operate on the matrix, one of which is a utility to compute statistics...