0

How can I select the optimal number of categories that better represent a continuous predictor in the single-variable linear regression model?

I constructed this scatter plot:

plt.scatter(train['pred'], train['resp'])
plt.show()

enter image description here

But it does not give me a clear idea. Is there any "automated" way?

Klausos
  • 499
  • 1
  • 6
  • 12

0 Answers0