https://365datascience.com/dwqa-answer/answer-for-value-error-expected-2d-array/ -
Hi Tanbir,
Thank you for reaching out.
Depending on your version of sklearn this may or may not be an issue. To turn the number to a 2D array, please add double square brackets like below:
reg.predict([[1740]])
Best,
Iliya
#365datascience #DataScience #data #science #365datascience #BigData #tutorial #infographic #career #salary #education #howto #scientist #engineer #course #engineer #MachineLearning #machine #learning #certificate #udemy
No comments:
Post a Comment