April 2017
Intermediate to advanced
532 pages
12h 39m
English
Linear regression is the most commonly used algorithm. At the core of the regression analysis is the task of fitting a single line through a data plot. Linear equation is described by y = c + b*x, where y = estimated dependent, c = constant, b = regression coefficients, and x = independent variable.
Let's train the bike sharing dataset by splitting it into 80% training and 20% testing, use LinearRegression with the regression evaluator from Spark to build the model, and get evaluation metrics around the test data. The linearRegressionWithVectorFormat method uses categorical data, whereas linearRegressionWithSVMFormat uses the libsvm format of the Bike-sharing dataset. ...
Read now
Unlock full access