Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Simple Linear Regression example using Python & Scikit-Learn
from sklearn import linear_model
ages = [
calories = [
ages_new = [[19],[36],[16],[64]]
Model = linear_model.LinearRegression(),calories)
score = Model.score(ages,calories)
print ("Score:",score)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.