01 C Practical measures the relationship between the x axis and y axis

Поделиться
HTML-код
  • Опубликовано: 20 сен 2024
  • Code:
    #It measures the relationship between the x axis and y axis
    #where O means no relationship, and 1 means totally related.
    import numpy
    from sklearn.metrics import r2_score
    numpy.random.seed(2)
    r2 = r2_score(train_y, mymodel(train_x))
    print(r2)
    #--------
    #Predict the values
    #Now that we have established that our model is OK, we can start prediction
    print(mymodel(5)) #check with graph
    Follow Me On
    Instagram : / mahapatropushpa
    LinkedIn : / pushpa-mahapatro

Комментарии •