Logistic Regression-Based Prediction of Stock Gap-Ups Using Technical Indicators

Authors

  • Yuan Anisa Universitas Medan Area
  • Muhammad Hafiz Universitas Negeri Medan
  • Hadijah Hadijah Universitas Negeri Medan
  • Abdul Gani Politeknik Unggul LP3M

DOI:

https://doi.org/10.55537/spk.v4i2.1334

Keywords:

Gap Up, Logistic Regression, Technical Analysis, Stock Prediction, Indonesia Stock Exchange

Abstract

This research aims to construct and test a predictive model for the gap-up phenomenon in stocks on the Indonesia Stock Exchange (IDX), with a case study on PT Bank Mandiri Tbk. (BMRI) stock. The research uses a quantitative approach by applying a Binary Logistic Regression model to analyze 1,213 daily historical data points from January 1, 2019, to January 1, 2024.Five technical analysis-based independent variables—vol_spike, rsi, prev_return, macd, and stochastic—were used to predict the probability of a stock gap-up occurrence.The analysis results show that the model as a whole is statistically significant (LLR p-value < 0.05), with an LLR p-value of (8.544e-11) and a Pseudo R-squared of 0.03389. Of the five variables, stochastic, macd, and prev_return were identified as significant predictors. Specifically, a high Stochastic Oscillator value has a strong positive influence on the probability of a gap-up. On the other hand, Moving Average Convergence Divergence (MACD) and Previous Return show a significant negative influence.These findings provide empirical evidence that a combination of technical indicators can be used to model and predict stock price movements at market opening. The implications of this research offer valuable insight for investors who rely on technical analysis as a basis for decision-making.

Downloads

Download data is not yet available.

References

T. Corvin, “What is a Stock Gap?,” The Trading Analyst. http://thetradinganalyst.com/what-is-a-stock-gap/

A. Avishay, C. Gil, and G. Vladimir, “Stocks Opening Price Gaps and Adjustments to New Information,” Comput. Econ., vol. 63, pp. 877–891, 2024. https://doi.org/10.1007/s10614-023-10363-w

S. R. Baker, N. Bloom, S. J. Davis, and M. C. Sammon, “What Triggers Stock Market Jumps?,” NBER Working Paper No. 28687, Apr. 2021, rev. Apr. 2025. https://www.nber.org/papers/w28687

A. Plastun, X. Sibande, R. Gupta, and M. E. Wohar, “Price gap anomaly in the US stock market: The whole story,” North Am. J. Econ. Finance, vol. 52, p. 101177, 2020. https://doi.org/10.1016/j.najef.2020.101177

Y. Shen and M. Shi, “Intraday variation in cross-sectional stock comovement and impact of index-based strategies,” J. Financ. Mark., vol. 68, 2024. https://doi.org/10.1016/j.finmar.2024.100894

R. Wilopo and I. A. Ekaputra, “Analysis of the Presence and Impact of Price Gap Anomaly on the Indonesian Stock Exchange,” Eduvest — J. Univ. Stud., vol. 5, no. 8, pp. 10192–10206, 2025. https://doi.org/10.59188/eduvest.v5i8.51416

Y. He, “A study of factors influencing investor expectations in the capital market,” in SHS Web Conf., vol. 188, p. 01020, 2024. https://doi.org/10.1051/shsconf/202418801020

A. Agresti, Foundations of Linear and Generalized Linear Models, 2nd ed., Hoboken, NJ: Wiley, 2021.

D. Hilbe, Practical Guide to Logistic Regression, 3rd ed., Boca Raton, FL: CRC Press, 2022.

U. Ananthakumar and R. Sarkar, “Application of Logistic Regression in Assessing Stock Performances,” in Proc. 2017 IEEE 15th Intl. Conf. DASC/PiCom/DataCom/CyberSciTech, Orlando, FL, USA, 2017, pp. 1242–1247. https://doi.org/10.1109/DASC-PICom-DataCom-CyberSciTec.2017.199

M. D. Kartikasari and R. D. Nafalana, “Predicting stock markets using binary logistic regression based on Bry-Boschan algorithm,” Jurnal Varian, vol. 6, no. 2, pp. 127–136, 2023. https://doi.org/10.30812/varian.v6i2.2385

S. S. Ali, M. Mubeen, I. Lal, and A. Hussain, “Prediction of Stock Performance by Using Logistic Regression Model: Evidence from Pakistan Stock Exchange (PSX),” vol. 8, no. 7, pp. 247–258, Jul. 2018. https://doi.org/10.18488/journal.1007/2018.8.7/1007.7.247.258

J. Yang, Y. Wang, and X. Li, “Prediction of stock price direction using the LASSO-LSTM model combines technical indicators and financial sentiment analysis,” PeerJ Comput. Sci., vol. 8, p. e1148, 2022. https://doi.org/10.7717/peerj-cs.1148

J. Eiglsperger, F. Haselbeck, and D. G. Grimm, “ForeTiS: A comprehensive time series forecasting framework in Python,” Machine Learn. Appl., vol. 12, p. 100467, 2023. https://doi.org/10.1016/j.mlwa.2023.100467

M. Bouasabah, “A Performance Analysis of Stochastic Processes and Machine Learning Algorithms in Stock Market Prediction,” Economies, vol. 12, no. 8, p. 194, 2024. https://doi.org/10.3390/economies12080194

A. K. Panigrahi, K. Vachhani, and S. K. Chaudhury, “Trend identification with the relative strength index (RSI) technical indicator – A conceptual study,” J. Manag. Res. Anal., vol. 8, no. 4, pp. 159–169, 2021. https://doi.org/10.18231/j.jmra.2021.033

A. A. Agudelo Aguirre, R. A. Rojas Medina, and N. D. Duque Méndez, “Machine learning applied in the stock market through the Moving Average Convergence Divergence (MACD) indicator,” Investment Manag. Financ. Innov., vol. 17, no. 4, pp. 44–60, 2020. https://doi.org/10.21511/imfi.17(4).2020.05

M. Kahssay and S. Miah, “A comparative analysis of stochastic models for stock price forecasting: The influence of historical data duration and volatility regimes,” Quant. Finance Econ., vol. 9, no. 3, pp. 602–630, 2025. https://doi.org/10.3934/QFE.2025021

M. I. Tabash, N. Chalissery, T. M. Nishad, and M. S. M. Al-Absy, “Market Shocks and Stock Volatility: Evidence from Emerging and Developed Markets,” Int. J. Financ. Stud., vol. 12, no. 1, p. 2, 2024. https://doi.org/10.3390/ijfs12010002

S. Hossain, B. Gavurová, X. Yuan, M. Hasan, and J. Oláh, “The impact of intraday momentum on stock returns: Evidence from S&P500 and CSI300,” E+M Ekonomie a Management, vol. 24, no. 4, pp. 124–141, Dec. 2021. https://doi.org/10.15240/tul/001/2021-4-008

D. Siahaan, I. Muda, and N. Irawati, “Efektifitas Penggunaan Analisis Stochastic Oscillator Dan Moving Average Convergence-Divergence Pada Perdagangan Saham-Saham Perbankan Di Bursa Efek Indonesia,” Owner: Riset dan Jurnal Akuntansi, vol. 8, no. 3, pp. 2565–2579, 2024. https://doi.org/10.33395/owner.v8i3.2250

“Bank Mandiri (Persero) Tbk (BMRI.JK) Historical Data,” Yahoo Finance. https://finance.yahoo.com/quote/BMRI.JK/history

G. Zeng and S. Tao, “A generalized linear transformation and its effects on logistic regression,” Mathematics, vol. 11, no. 2, p. 467, 2023. https://doi.org/10.3390/math11020467

J. Salinas Ruíz, O. A. Montesinos López, G. Hernández Ramírez, and J. Crossa Hiriart, “Generalized Linear Models,” in Generalized Linear Mixed Models with Applications in Agriculture and Biology, Cham: Springer, 2023, ch. 2. https://doi.org/10.1007/978-3-031-32800-8_2

D. Dey, M. S. Haque, M. M. Islam, et al., “The proper application of logistic regression model in complex survey data: a systematic review,” BMC Med. Res. Methodol., vol. 25, p. 15, 2025. https://doi.org/10.1186/s12874-024-02454-5

T.-T. Ho and Y. Huang, “Stock Price Movement Prediction Using Sentiment Analysis and CandleStick Chart Representation,” Sensors, vol. 21, no. 23, p. 7957, 2021. https://doi.org/10.3390/s21237957

Downloads

Published

2025-09-30

How to Cite

[1]
Y. Anisa, M. Hafiz, H. Hadijah, and A. Gani, “Logistic Regression-Based Prediction of Stock Gap-Ups Using Technical Indicators”, SPK dengan Aplikasi, vol. 4, no. 2, pp. 95–100, Sep. 2025.

Issue

Section

Articles