This project involved predicting trends in gold prices—such as whether they would rise, fall, or remain stable—using a Random Forest Classifier. The objective was to leverage historical data and market indicators to assist in decision-making for investments and risk management.
Methodology:
Data Collection and Preprocessing:
Worked with a dataset comprising historical gold prices, crude oil prices, stock market indices, and currency exchange rates.
Preprocessed the data by handling missing values, encoding categorical variables, and normalizing numerical features.
Target Engineering:
Transformed continuous gold price data into categories like Increase, Decrease, and No Change based on price thresholds.
Model Training:
Implemented a Random Forest Classifier to handle multi-class classification, utilizing its ability to handle high-dimensional and imbalanced data.
Model Optimization:
Tuned hyperparameters such as the number of trees, maximum depth, and class weights using grid search for optimal performance.
Key Results and Insights:
Achieved an accuracy of XX% with strong precision and recall metrics for all classes.
Identified significant predictors, including currency exchange rates and stock indices, that influenced gold price trends.
Demonstrated the Random Forest Classifier’s ability to handle non-linear relationships and provide interpretable feature importance metrics.
Skills and Tools:
Machine Learning (Random Forest Classifier), Python (Pandas, NumPy, Scikit-learn, Matplotlib, Seaborn), Data Preprocessing, and Model Evaluation.
This project showcases the application of machine learning in financial analysis, providing valuable insights into market behavior and enabling data-driven investment strategies.
Github Project link: https://github.com/sm98code/ML.git
Visualization Result