import numpy as np
from sklearn.tree import DecisionTreeRegressor
import matplotlib.pyplot as plt
%matplotlib inline
n = 100
x = np.random.rand(n)*6 - 3
x.sort()
y = np.sin(x) + np.random.rand(n) + 0.06
x = x.reshape(-1,1)
y = y.reshape
(DecisionTreeRegressor)决策树回归预测实例-max_depth 学习笔记
最新推荐文章于 2025-03-18 11:21:19 发布