Question: def _ _ init _ _ ( self ) : # Your code starts after this line # Your code ends before this line def

def __init__(self):
# Your code starts after this line
# Your code ends before this line
def train(self, data, column, values):
# Your code starts after this line
# Your code ends before this line
def predict(self):
# Your code starts after this line
# Your code ends before this line
import pandas as pd
data = pd.read_csv("data/da-week1.csv")
model1= model()
model1.train(data,'X',['A','B','C','D'])
print('Model 1 prediction: '+ model1.predict())
model2= model()
model2.train(data,'Y', range(1,11))
print('Model 2 prediction: '+str(model2.predict()))

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!