STOCK MARKET PREDICTION USING NEURAL NETWORKS

Page 1

International Research Journal of Engineering and Technology (IRJET) e ISSN:2395 0056

Volume: 09 Issue: 06 | June 2022 www.irjet.net p ISSN:2395 0072

STOCK MARKET

PREDICTION

USING NEURAL NETWORKS

Manas Kantimahanti1 , Bharat Thakkar2 , Kanishka Bisen3 , Prof. Ramesh Mali

1Manas Kantimahanti, Dept. of Electronics Communication Engineering, Pune

2Bharat Thakkar, Dept. of Electronics Communication Engineering, Pune

3Kanishka Bisen, Dept. of Electronics Communication Engineering, Pune

4Professor Dr. Ramesh Mali, Dept. of ECE, MIT School of Engineering, Pune, Maharashtra, India ***

Abstract This paper provides an overview of a Financial Modelling technique for predicting the closing prices of Stocks. The paper describes how LSTM models aredesignedandimplemented.Thepaperalsoshowsthat future stock prices can be predicted using Machine Learning and training the Neural Network with the previousyears’‘stockclosingprice’data.

Key Words: Stock Market, LSTM, Neural Networks, Prediction.

1. INTRODUCTION

The financial market is a dynamic and composite system wherepeoplecanbuyandsellcurrencies,stocks,equities, and derivatives over virtual platforms supported by brokers. Thestockmarketallowsinvestors toownshares ofpubliccompaniesthroughtradingeitherbyexchangeor over the countermarkets.Thismarkethasgiveninvestors thechance of gaining money and havinga prosperous life throughinvestingsmallinitialamountsofmoney,lowrisk compared to the risk of opening a new business or the need for a high salary career. Stock markets are affected by many factors causing uncertainty and high volatility in the market. Although humans cantake orders and submit themtothemarket,automatedtradingsystems(ATS)that are operated by the implementation of computer programscanperformbetterandwithhighermomentum in submitting orders than any human. However, to evaluate and control the performance of ATSs, the implementation of risk strategies and safety measures applied based on human judgments are required. Many factorsareincorporated andconsidered whendeveloping an ATS, for instance, trading strategy to be adopted, complex mathematical functions that reflect the state of a specificstock,machinelearningalgorithmsthatenablethe prediction of the future stock value, and specific news relatedtothestockbeinganalyzed.

Time series prediction is a common technique widely used in many real world applications such as weather forecasting and financial market prediction. It uses continuousdataoversometimetopredicttheresultinthe next time unit. Many time series prediction algorithms have shown their effectiveness in practice. The most

common algorithms now are based on Recurrent Neural Networks (RNN), as well as its special type Long short Term Memory (LSTM). The stock market is a typical area thatpresentstime seriesdataandmanyresearchersstudy it and proposed various models. In this project, the LSTM modelisusedtopredictthestockprice.

1.1 DESIGN GOALS

To make the project runs smoothly it’s required that we make a plan and design some accepts like flowcharts and systemarchitecturewhicharedefinedbelow.

1.2 Data Collection

Datacollectionisoneoftheimportantandbasicobjectives of our project. The right dataset must be provided to get robust results. Our data mainly consists of the previous year’s or week’s stock prices. We will be taking and analyzingdatafromKaggle.Afterthatseeingtheaccuracy wewillusethedatainourmodel.

1.3 Data Preprocessing

Humanscanunderstand anytypeofdatabut themachine can’tourmodelwillalsolearnfromscratchsoit’sbetterto makethedatamoremachine readable.Rawdataisusually inconsistent or incomplete. Data preprocessing involves checking missing values, splittingthedataset andtraining themachine,etc.

1.4 Training Model

Similar to feeding some things, machines/models should also learn by feeding and learning on data. The data set extractedfromKagglewillbeusedtotrainthemodel.The training model uses a raw set of data as the undefined dataset which is collected from the previous fiscal year and from the same dataset a refine view is presented whichisseenasthedesiredoutput.Fortherefiningofthe dataset, various algorithms are implemented to show the desiredoutput.

2. System Requirements

This project can run on commodity hardware. We ran an entireprojectonanIntelI5processorwith8GBRam,and

© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page1800

International Research Journal of Engineering and Technology (IRJET)

e ISSN:2395 0056

Volume: 09 Issue: 06 | June 2022 www.irjet.net p ISSN:2395 0072

2 GB Nvidia Graphic Processor, It also has 2 cores which runat1.7GHz,and2.1GHzrespectivelyfirstpartoftheis training phase which takes 10 15 mine and the second partis testing part which only takes few seconds to make predictionsandcalculateaccuracy.

2.1 Hardware Requirements:

• RAM: 4 GB

• Storage: 500 GB

• CPU: 2 GHz or faster

• Architecture: 32 bit or 64 bit

2.2 Software requirements

•Python3.5inGooglecollabisusedfordataprocessing, modeltraining,andprediction.

•OperatingSystemWindows7andaboveorLinux based orMACOS.

System Architecture: Working on LSTM Model

Lengthybrief termmemoryis aform ofrecurrent neuralcommunity InRNNoutputfromthefinalstepisfed asinputinthepresentstep.Ittackledtheproblemoflong time perioddependencies of RNNinsidewhich the RNN willnow notexpectthephraseholdonin thelong time periodreminiscencebut,canofferadditionalcorrectforeca sts from thelatestinfo Becausethe gaplengthwill increaseRNN doesnow notoffera cost effectiveperformance LSTM willwith the aid ofdefaultretaintheinformationforan extendedlengthandit's farused for processing, predicting, and classifyingbased totallyon time seriesstatistics

Table 1: LiteratureReview

StockmarketPred ictionbyLSTM

© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page1801
PublicationsandAuthor
1 VKranthiSaiReddystudent, ECM,SreenidhiInstitute oftechnologyandtechnology,
Sr.No.
Title
Hyderabad,India
2 DharmarajaSelvamuthu,Vineet Kumar,andAbhishekMishra DepartmentofMathematics, IndianInstituteofTechnology Delhi
MariamMoukalledWassimEl HajjTheMohamadJaber ComputerScienceDepartment AmericanUniversityofBeirut.
MohamedHAMICHE, InternationalWorkshopon
ArtificialIntelligence
Stockmarket predictionand usageofthe system
inventorymarket predictionusingar tificialneural networkson tickdata 3
computerizedstoc kfeePredictionof theusage ofdevicelearning 4
StatisticalMethodsand

International Research Journal of Engineering and Technology (IRJET) e ISSN:2395 0056

Volume: 09 Issue: 06 | June 2022 www.irjet.net p ISSN:2395 0072

3. Design, Development, and Drawings

DESIGN GOALS

3.1.1 Data Collection

Data collection is one of the important and basic tasks in our project. The right dataset must be provided to get robust results. Our data mainly consists of the previous year’s or week’s stock prices. We will be taking and analyzing data from Kaggle. Now, by seeing the accuracy, wewillusethedatainourmodel.

3.1.2 Data Preprocessing

Humans can understand any type of data but machines can’tourmodelwillalsolearnfromscratchsoit’sbetterto makethedatamoremachine readable.Rawdataisusually inconsistent or incomplete. Data Preprocessing involves checking missingvalues, splitting thedatasetandtraining themachine,etc.

3.1.3 Training Model

Similar to feeding some things, machines/mods should also learn by feeding and learning on data. The data set extractedfromKagglewillbeusedtotrainthemodel.The training model uses a raw set of data as the undefined dataset which is collected from the previous fiscal year and from the same dataset a refine view is presented whichisseenasthedesiredoutput.Fortherefiningofthe dataset, various algorithms are implemented to show the desiredoutput.

3.2 LSTM Memory Cell

3.3 Working of LSTM Model

LongShort termreminiscenceisasortofrecurrentneural network. InRNN outputfromthe remaining stepis fed as inputwithinthegiftstep.Ittackledthematteroflengthy termdependenciesofRNN withinwhichtheRNN will not predict the phrase maintain on within the long time reminiscence but can offer additional correct forecasts from the recent data. Because the space length will increases RNN does now not provide a cost effective overall performance. LSTM will via default maintain the understanding for a long period. It’s miles used for processing, predicting, and classifying based on time seriesfacts.

4. Results

4.1 Stock Closing Prices Obtained

© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page1802
3.1
To make the project runs smoothly it’s required that we makeplananddesign Someacceptflowchartsandsystemarchitecturewhichare definedbelow
4.2 Stock Closing Prices Visualised

International Research Journal of Engineering and Technology (IRJET) e ISSN:2395 0056

Volume: 09 Issue: 06 | June 2022 www.irjet.net p ISSN:2395 0072

academics, and support throughout the project, without his great concepts & inspiration it would have been impossible.

Ithankmyparentsfortheemotionalandfinancialsupport theyprovidedduringthisproject.

We show gratitude to our Honorable Principal Prof. Dr. KishoreRavande,forhavingprovidedallthefacilitiesand support.

I thank all faculties who directly and indirectly helped us inthecompletionofthisproject.

REFERENCES

5. CONCLUSIONS

Inthisproject,wearepredictingtheclosingstockpriceof any given organization, we developed a web application forpredictingclosestockpriceusingLSTMalgorithmsfor prediction.

In our project, various high level machine learning algorithms are implemented and integrated and the output is generated from the same making a user visible withthe

Outputs in the form of a graph make it easier for them to seeand interpret what’s the scenario andtheycan decide onthesametoinvestinandgetthebenefitoutofit.

To conclude stock is an unpredictable mechanism that followsthesegmentsofthechainandthedependenciesof thesameareunpredictable.Itisdefinedtobeacurve

Which keeps on changing and turning the price from low tohighandvice versa.

6. ACKNOWLEDGEMENT

The satisfaction that accompanies the successful completion of the task would be put incomplete without the mention of the people who made it possible, whose constant guidance and encouragement crown all the effortswithsuccess.

It is my greatest pleasure to thank Prof. Dr. Virendra V. Shete (Vice Principal, MIT SOE, and Head, Department of Electronics and Communication, MIT ADT University) for providing us heart full encouragement and support and allowing us to work in such a resourceful lab of this esteemed institute and thereby fulfilling one of my dreams. I wholeheartedly thank my project guide, Dr. Ramesh Mali, for his consistent guidance, expert

[1] “Stock fee prediction the use of LSTM, RNN and CNN sliding window model IEEE convention guide.” https://ieeexplore.ieee.org/file/8126078 (accessed Dec. 27,2019).

[2]J.Jagwani,M.Gupta,H.Sachdeva,andA.Singhal,“stock priceForecastingtheusageofrecordsfromYahooFinance andAnalysingSeasonalandNonseasonalfashion,”in2018 2nd international conference on clever Computing and control systems (ICICCS), Madurai, India, Jun. 2018, pp. 462 467,DOI:10.1109/ICCONS.2018.8663035.

[3] I. Parmar et al., “inventory Dec. 2018, pp. 574 576, DOI:10.1109/ICSCCC.2018.8703332.

[4] Y. Lei, ok. Zhou, and Y. Liu, “Multi category occasions pushedstockchargetrendsPrediction,”in2018fifthIEEE international conference on Cloud Computing and Intelligence structures (CCIS), Nanjing, China, Nov. 2018, pp.497 501,DOI:

10.1109/CCIS.2018.8691392.

[5] B. Jeevan, E. Naresh, B. P. V.Kumarr, and P. Kambli, “percentageratePredictiontheuseof

System studying approach,” in 2018 third international conference on Circuits, manage, verbal exchange and Computing(I4C),Bangalore,India,Oct.2018,pp.1 4,DOI: 10.1109/CIMCA.2018.8739647.

[6]M.Usmani,S.H.Adil,k.Raza,andS.S.A.Ali,“inventory marketplace prediction using machine getting to know techniques,” in 2016 third worldwide conference on computer and statistics Sciences (ICCOINS), 2016, pp. 322 327.

[7] J. Du, Q. Liu, okay. Chen, and J. Wang, “Forecasting inventory charges in methods based totally on LSTM neuralnetwork,”in2019IEEEthirddataera,Networking, digital and Automation manipulate conference (ITNEC),

© 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal | Page1803 4.3
Predicted Stock Prices of TATA Motors

International Research Journal of Engineering and Technology (IRJET) e ISSN:2395 0056

Mar. 2019, pp. 1083 1086, D OIi: 10.1109/ITNEC.2019.8729026.

[8]S.E.GAO,B.S.Lin,andC. M.Wang,“proportioncharge trend Prediction using CRNN with LSTM shape,” in 2018 worldwide Symposium on the computer, consumer and manipulate (IS3C), Dec. 2018, pp. 10 thirteen, DOI: 10.1109/IS3C.2018.00012.

[9] T. Gao, Y. Chai, and Y. Liu, “applying long quick time period memory neural networks for predicting inventory remainingfee,”in20178thIEEEworldwideconventionon software program Engineering and carrier technology (ICSESS), Beijing, China, Nov. 2017, pp. 575 578, DOI: 10.1109/ICSESS.2017.8342981.

Volume: 09 Issue: 06 | June 2022 www.irjet.net p ISSN:2395 0072 © 2022, IRJET | Impact Factor value: 7.529 | ISO 9001:2008 Certified Journal |

Page1804

Turn static files into dynamic content formats.

Create a flipbook