Classification

Here's the snippet to create the classification RDD of labeled points that we will be using to predict whether someone is making more than $50,000:

final_data_income = (
    final_data
    .map(lambda row: reg.LabeledPoint(
        row[0]
        , row[1:]
        )
)
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset