Added Random Forest Regressor as an additional prediction model.#12767
Added Random Forest Regressor as an additional prediction model.#12767priyanshu-8789 wants to merge 14 commits into
Conversation
|
Implemented RandomForestRegressor alongside SVR and SARIMAX |
for more information, see https://pre-commit.ci
|
Added Random Forest Regressor to main voting |
|
Hi @poyea, |
|
Hi @TheAlgorithms, |
Used matplotlib to plot actual vs predicted user count, forecast confidence intervals, outlier thresholds from IQR. Added logging instead of print because in production, print() is not scalable.
for more information, see https://pre-commit.ci
|
Hi @TheAlgorithms, |
There was a problem hiding this comment.
Pull request overview
This PR extends the existing forecasting “voting” script by adding a Random Forest–based regressor as an additional prediction option, and introduces a small visualization helper for comparing predictions. It also updates the repository’s directory index.
Changes:
- Add
random_forest_regressor()(sklearn) and include it in theres_voteensemble. - Add
plot_forecast()(matplotlib) and call it from the__main__block to visualize results. - Update
DIRECTORY.mdto add a Geometry index entry.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| machine_learning/forecasting/run.py | Adds RandomForestRegressor forecasting method and a matplotlib plotting helper; integrates both into the main execution path. |
| DIRECTORY.md | Adds a Geometry section index entry (“Segment Intersection”). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| return safe > not_safe | ||
|
|
||
|
|
||
| def plot_forecast(actual, predictions): |
Describe your change:
Implemented RandomForestRegressor alongside SVR and SARIMAX
Checklist: