Refining ADAM optimizer in LSTM to improve the stock price prediction over HMM and GMM

preprint OA: closed CC-BY-4.0
📄 Open PDF Full text JSON View at publisher

Abstract

Abstract Forecasting Stock prices is a critical challenge in financial markets due to their dynamic and volatile nature. These forecasts may be made more accurate by applying advanced machine learning methods. This study aims to enhance the accuracy of predicting a stock's next day's closing price by employing Long Short-Term Memory (LSTM) networks and performing a comparative analysis between LSTM networks and the Hidden Markov Model-Gaussian Mixture Model (HMM-GMM) approach. Along with Stochastic Gradient Descent and ADAM, two modified ADAM algorithms were also implemented to improve the performance of LSTM. This study also includes a detailed breakdown of the LSTM algorithm to better understand the intricacies of LSTM. Historical stock price data was used as input to train and validate the LSTM network. The model's predictions were then compared with the results obtained from the HMM-GMM method using the Mean Absolute Percentage Error (MAPE) as the evaluation metric. The results demonstrate that the LSTM with modified ADAM optimisers outperform the HMM-GMM model in accurately predicting the next day's closing prices. The value of this research lies in exploring the nuances of LSTM. This paper discusses the different gates inside LSTM, backpropagation about each gate, and various layers, along with their corresponding derivations and equations. This research has successfully increased the accuracy of forecasting a stock's subsequent day's closing price by using the Long Short-Term Memory (LSTM) networks. The improved accuracy of our model shows that LSTM can be used by investors to better predict stock prices. The detailed exploration of LSTM architecture presented in this study contributes to the broader understanding of advanced machine learning models.
Full text 11,258 characters · extracted from preprint-html · click to expand
Refining ADAM optimizer in LSTM to improve the stock price prediction over HMM and GMM | Research Square window.SnipcartSettings = { analytics: { enabled: false } }; (function() { var accessVector = localStorage.getItem('access_vector') || ''; window.dataLayer = window.dataLayer || []; if (accessVector) { window.dataLayer.push({ user: { profile: { profileInfo: { snid: accessVector } } } }); } })(); (function(w,d,s,l,i){w[l]=w[l]||[];w[l].push({'gtm.start':new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],j=d.createElement(s),dl=l!='dataLayer'?'&l='+l:'';j.async=true;j.src='https://www.googletagmanager.com/gtm.js?id='+i+dl;f.parentNode.insertBefore(j,f);})(window,document,'script','dataLayer','GTM-K279D39R'); Browse Preprints In Review Journals COVID-19 Preprints AJE Video Bytes Research Tools Research Promotion AJE Professional Editing AJE Rubriq About Preprint Platform In Review Editorial Policies Our Team Advisory Board Help Center Sign In Submit a Preprint Cite Share Download PDF Research Article Refining ADAM optimizer in LSTM to improve the stock price prediction over HMM and GMM Dr M Punniyamoorthy, R Balu, Naren Meenakshi Sundaram S This is a preprint; it has not been peer reviewed by a journal. https://doi.org/ 10.21203/rs.3.rs-6219867/v1 This work is licensed under a CC BY 4.0 License Status: Posted Version 1 posted You are reading this latest preprint version Abstract Forecasting Stock prices is a critical challenge in financial markets due to their dynamic and volatile nature. These forecasts may be made more accurate by applying advanced machine learning methods. This study aims to enhance the accuracy of predicting a stock's next day's closing price by employing Long Short-Term Memory (LSTM) networks and performing a comparative analysis between LSTM networks and the Hidden Markov Model-Gaussian Mixture Model (HMM-GMM) approach. Along with Stochastic Gradient Descent and ADAM, two modified ADAM algorithms were also implemented to improve the performance of LSTM. This study also includes a detailed breakdown of the LSTM algorithm to better understand the intricacies of LSTM. Historical stock price data was used as input to train and validate the LSTM network. The model's predictions were then compared with the results obtained from the HMM-GMM method using the Mean Absolute Percentage Error (MAPE) as the evaluation metric. The results demonstrate that the LSTM with modified ADAM optimisers outperform the HMM-GMM model in accurately predicting the next day's closing prices. The value of this research lies in exploring the nuances of LSTM. This paper discusses the different gates inside LSTM, backpropagation about each gate, and various layers, along with their corresponding derivations and equations. This research has successfully increased the accuracy of forecasting a stock's subsequent day's closing price by using the Long Short-Term Memory (LSTM) networks. The improved accuracy of our model shows that LSTM can be used by investors to better predict stock prices. The detailed exploration of LSTM architecture presented in this study contributes to the broader understanding of advanced machine learning models. Long Short-Term Memory Hidden Markov Model-Gaussian Mixture Model Neural Network Recurrent Neural Network Gradient Descent Adam optimizer Full Text Additional Declarations No competing interests reported. Cite Share Download PDF Status: Posted Version 1 posted You are reading this latest preprint version Research Square lets you share your work early, gain feedback from the community, and start making changes to your manuscript prior to peer review in a journal. As a division of Research Square Company, we’re committed to making research communication faster, fairer, and more useful. We do this by developing innovative software and high quality services for the global research community. Our growing team is made up of researchers and industry professionals working together to solve the most critical problems facing scientific publishing. Also discoverable on Platform About Our Team In Review Editorial Policies Advisory Board Help Center Resources Author Services Accessibility API Access RSS feed Manage Cookie Preferences © Research Square 2026 | ISSN 2693-5015 (online) Privacy Policy Terms of Service Do Not Sell My Personal Information {"props":{"pageProps":{"initialData":{"identity":"rs-6219867","acceptedTermsAndConditions":true,"allowDirectSubmit":true,"archivedVersions":[],"articleType":"Research Article","associatedPublications":[],"authors":[{"id":438458260,"identity":"fe2b23ff-f4cd-4e72-ae4b-9d93bc885d83","order_by":0,"name":"Dr M Punniyamoorthy","email":"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAZAAAAAyAQMAAABI0h/eAAAABlBMVEX///8AAABVwtN+AAAACXBIWXMAAA7EAAAOxAGVKw4bAAAAtUlEQVRIiWNgGAWjYLCCBAYGOQZmMJOZeC3GDMzMjA3EawGCxAYGYrWYS+Qee/CwzS59Ozv/8QcMFdZAvQSA5Yy8dIPEtuTcnc0gW86kE9ZicCPHTCKxjTl3w2GgFsa2w0RrqU83AGv5R7yWwwkQLQ1EaLHseWMmkXDuuCHQYYYzEo6lGxPUYs6eYyb5o6xa3uD8wQcfPtRYyxJ2GIhgZIPyEggph2th+EOM0lEwCkbBKBixAAD+8TxpEJuxFgAAAABJRU5ErkJggg==","orcid":"","institution":"National Institute of Technology","correspondingAuthor":true,"prefix":"Dr","firstName":"M","middleName":"","lastName":"Punniyamoorthy","suffix":""},{"id":438458261,"identity":"bf657aef-b21c-4d58-9ebd-b40e819eeaae","order_by":1,"name":"R Balu","email":"","orcid":"","institution":"National Institute of Technology","correspondingAuthor":false,"prefix":"","firstName":"R","middleName":"","lastName":"Balu","suffix":""},{"id":438458262,"identity":"907efc91-dfb2-4f1d-8423-ab735dada284","order_by":2,"name":"Naren Meenakshi Sundaram S","email":"","orcid":"","institution":"National Institute of Technology","correspondingAuthor":false,"prefix":"","firstName":"Naren","middleName":"Meenakshi Sundaram","lastName":"S","suffix":""}],"badges":[],"createdAt":"2025-03-13 12:08:05","currentVersionCode":1,"declarations":"","doi":"10.21203/rs.3.rs-6219867/v1","doiUrl":"https://doi.org/10.21203/rs.3.rs-6219867/v1","draftVersion":[],"editorialEvents":[],"editorialNote":"","failedWorkflow":false,"files":[{"id":80127087,"identity":"508411a8-154d-4d76-828e-e660f67524bd","added_by":"auto","created_at":"2025-04-08 08:35:16","extension":"pdf","order_by":1,"title":"","display":"","copyAsset":false,"role":"manuscript-pdf","size":2067530,"visible":true,"origin":"","legend":"","description":"","filename":"Manuscript.pdf","url":"https://assets-eu.researchsquare.com/files/rs-6219867/v1_covered_059952ba-46fc-4ef8-92b2-6716c586f1d5.pdf"}],"financialInterests":"No competing interests reported.","formattedTitle":"Refining ADAM optimizer in LSTM to improve the stock price prediction over HMM and GMM","fulltext":[],"fulltextSource":"","fullText":"","funders":[],"hasAdminPriorityOnWorkflow":false,"hasManuscriptDocX":false,"hasOptedInToPreprint":true,"hasPassedJournalQc":"","hasAnyPriority":true,"hideJournal":true,"highlight":"","institution":"","isAcceptedByJournal":false,"isAuthorSuppliedPdf":true,"isDeskRejected":"","isHiddenFromSearch":false,"isInQc":false,"isInWorkflow":false,"isPdf":true,"isPdfUpToDate":true,"isWithdrawnOrRetracted":false,"journal":{"display":true,"email":"[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true},"keywords":"Long Short-Term Memory, Hidden Markov Model-Gaussian Mixture Model, Neural Network, Recurrent Neural Network, Gradient Descent, Adam optimizer","lastPublishedDoi":"10.21203/rs.3.rs-6219867/v1","lastPublishedDoiUrl":"https://doi.org/10.21203/rs.3.rs-6219867/v1","license":{"name":"CC BY 4.0","url":"https://creativecommons.org/licenses/by/4.0/"},"manuscriptAbstract":"\u003cp\u003eForecasting Stock prices is a critical challenge in financial markets due to their dynamic and volatile nature. These forecasts may be made more accurate by applying advanced machine learning methods. This study aims to enhance the accuracy of predicting a stock's next day's closing price by employing Long Short-Term Memory (LSTM) networks and performing a comparative analysis between LSTM networks and the Hidden Markov Model-Gaussian Mixture Model (HMM-GMM) approach. Along with Stochastic Gradient Descent and ADAM, two modified ADAM algorithms were also implemented to improve the performance of LSTM. This study also includes a detailed breakdown of the LSTM algorithm to better understand the intricacies of LSTM. Historical stock price data was used as input to train and validate the LSTM network. The model's predictions were then compared with the results obtained from the HMM-GMM method using the Mean Absolute Percentage Error (MAPE) as the evaluation metric. The results demonstrate that the LSTM with modified ADAM optimisers outperform the HMM-GMM model in accurately predicting the next day's closing prices. The value of this research lies in exploring the nuances of LSTM. This paper discusses the different gates inside LSTM, backpropagation about each gate, and various layers, along with their corresponding derivations and equations. This research has successfully increased the accuracy of forecasting a stock's subsequent day's closing price by using the Long Short-Term Memory (LSTM) networks. The improved accuracy of our model shows that LSTM can be used by investors to better predict stock prices. The detailed exploration of LSTM architecture presented in this study contributes to the broader understanding of advanced machine learning models.\u003c/p\u003e","manuscriptTitle":"Refining ADAM optimizer in LSTM to improve the stock price prediction over HMM and GMM","msid":"","msnumber":"","nonDraftVersions":[{"code":1,"date":"2025-04-08 08:27:07","doi":"10.21203/rs.3.rs-6219867/v1","editorialEvents":[{"type":"communityComments","content":0}],"status":"published","journal":{"display":true,"email":"[email protected]","identity":"researchsquare","isNatureJournal":false,"hasQc":true,"allowDirectSubmit":true,"externalIdentity":"","sideBox":"","snPcode":"","submissionUrl":"/submission","title":"Research Square","twitterHandle":"researchsquare","acdcEnabled":true,"dfaEnabled":false,"editorialSystem":"","reportingPortfolio":"","inReviewEnabled":false,"inReviewRevisionsEnabled":true}}],"origin":"","ownerIdentity":"320c9c89-3964-48c7-a21f-ac106a7c704a","owner":[],"postedDate":"April 8th, 2025","published":true,"recentEditorialEvents":[],"rejectedJournal":[],"revision":"","amendment":"","status":"posted","subjectAreas":[],"tags":[],"updatedAt":"2025-04-08T08:27:07+00:00","versionOfRecord":[],"versionCreatedAt":"2025-04-08 08:27:07","video":"","vorDoi":"","vorDoiUrl":"","workflowStages":[]},"version":"v1","identity":"rs-6219867","journalConfig":"researchsquare"},"__N_SSP":true},"page":"/article/[identity]/[[...version]]","query":{"redirect":"/article/rs-6219867","identity":"rs-6219867","version":["v1"]},"buildId":"8U1c8b4HqxoKbykW_rLl7","isFallback":false,"isExperimentalCompile":false,"dynamicIds":[84888],"gssp":true,"scriptLoader":[]}

Text is read by the "Ask this paper" AI Q&A widget below. Extraction quality varies by source — PMC NXML preserves structure cleanly, OA-HTML may include some navigation residue, and OA-PDF can have broken hyphenation. The publisher copy (via DOI) is the canonical version.

My notes (saved in your browser only)

Ask this paper AI returns verbatim quotes from the full text · source: preprint-html

Answers must be backed by verbatim quotes from this paper's full text. Hallucinated quotes are dropped automatically; if no verbatim passage answers the question, we say so. How this works

Citation neighborhood (no data yet)

We don't have any in-corpus citations linked to this paper yet. This is a recent paper (2025) — citers typically take a year or two to land, and the OpenAlex reference graph may still be filling in.

Source provenance

europepmc
last seen: 2026-05-20T01:45:00.602351+00:00
unpaywall
last seen: 2026-05-30T02:00:01.510937+00:00
License: CC-BY-4.0