1from sklearn.ensemble import RandomForestRegressor
2from sklearn.datasets import make_regression
3X, y = make_regression(n_features=4, n_informative=2,
4 random_state=0, shuffle=False)
5regr = RandomForestRegressor(max_depth=2, random_state=0)
6regr.fit(X, y)
7
8print(regr.predict([[0, 0, 0, 0]]))