Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

how to use random tree in python

from sklearn.ensemble import RandomForestRegressor

regressor = RandomForestRegressor(n_estimators=20, random_state=0)
regressor.fit(X_train, y_train)
y_pred = regressor.predict(X_test)
Source by stackabuse.com #
 
PREVIOUS NEXT
Tagged: #random #tree #python
ADD COMMENT
Topic
Name
9+2 =