Forecasting stock index prices remains a challenging task because financial markets are volatile, non-stationary, and influenced by several economic and behavioral factors.This study evaluates 12 supervised machine learning models against a Naïve Persistence baseline for predicting next-day open and close prices of the NIFTY 50 index across 5-year, 10year, and 20-year historical windows.The study compares two feature settings: one based on raw open, high, low, close, and volume variables and another that augments these variables with derived indicators such as the Simple Moving Average, Relative Strength Index, daily return, and rolling volatility.The evaluated models include Linear Regression, Lasso, Ridge, Elastic Net, Stochastic Gradient Descent Regressor, Support Vector Regression, K-Nearest Neighbors, Decision Tree, Random Forest, Gradient Boosting Regressor, AdaBoost Regressor, and eXtreme Gradient Boosting (XGBoost).The models are compared based on Mean Absolute Error, Root Mean Squared Error, and the R² score under chronological train-test splitting.The results show that linear models, particularly Linear Regression, Ridge, and Lasso, provide more stable generalization across 10-year and 20-year historical windows and consistently outperform the naïve benchmark.In contrast, Random Forest and XGBoost perform competitively in the 5-year setting but show weaker generalization for the 10-year and 20-year windows, often performing worse than a simple naïve forecast, even after hyperparameter tuning using TimeSeriesSplit.The findings suggest that simple linear models can serve as strong baselines for NIFTY 50 open and close price forecasting under the considered experimental setting.
No takes yet. Share an insight, caveat, or question.
Sain et al. (2026) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: