predition model for stock price on big data analytics

3
International Journal of Tre Volume 3 Issue 5, August 20 @ IJTSRD | Unique Paper ID – IJTSRD2 Predition Model Thin Thi Lecturer, Faculty of Informat How to cite this paper: Thin Thin Swe | Phyu Phyu | Sandar Pa Pa Thein "Predition Model for Stock Price on Big Data Analytics" Published in International Journal of Trend in Scientific Research and Development (ijtsrd), ISSN: 2456- 6470, Volume-3 | Issue-5, August 2019, pp.1444-1446, https://doi.org/10.31142/ijtsrd26660 Copyright © 2019 by author(s) and International Journal of Trend in Scientific Research and Development Journal. This is an Open Access article distributed under the terms of the Creative Commons Attribution License (CC BY 4.0) (http://creativecommons.org/licenses/by /4.0) The Analyses Of Information That Is A Different Business Activities By Compani Better Understanding The Needs Of Their Preditions Future Trends. It Was Previou Several Research Papers That Precise Finan A. Big Data There are several definitions what Big data following: "Big data refers to datasets who the ability of typical database software t store, manage, and analyse." [2] This defini key aspects of big data that are volume, vel [3]. According to IBM reports [4] everyday bytes of data" is created. These figures are year. This is due to previously described ubi the Internet and growing number of device and delivered from various systems opera For example social media platforms aggr information about user activities and intera most popular social sites Facebook has o daily active users [5]. Output rate of the sy important when nearly real-time analyses But big data is not only challenging but p opportunities. They are, among the o transparency, optimization and improvin generation of additional profits and no discovering new ideas, services and produ B. Social Media Twitter is an online news and social netwo people can communicate in short messag IJTSRD26660 end in Scientific Research and Dev 019 Available Online: www.ijtsrd.com e- 26660 | Volume – 3 | Issue – 5 | July - Augus for Stock Price on Big Data in Swe, Phyu Phyu, Sandar Pa Pa Thein tion Science, Universtiy of Computer Studies, P y ABSTRACT Prediction in the stock market is very challengin available from Twitter micro blogging platform market records. Machine learning was employ t of data and to estimate for future stock pr sentiments and the stock value is to be determ these algorithms: Multiple linear Regression, S Artificial Neural Network are done. KEYWORDS: Stock Market; Sentiment Analysi (MLR); Support Vector Machine (SVM); Artificial I. INTRODUCTION The Stock Market Is Always One Of The Most Po High Profit. Recent Years Have Shown Not Only Widespread Attempts To Analyse It For Prac Computer Engineers Have Crated Special Term “ Main Features Of Big Data Are Volume, Variety A The Amount Of Data, Variety Refers To The N Velocity Refers To The Speed Of Data Processin There Are Many Reasons To Grow Of Big Data Computer Systems Start To Be Used In Many S Governments And Local Authories To Help To F A By-Product Of ies Can Lead To r Customers And usly Reported In ncial Markets [1]. a is , one of them is ose size is beyond tools to capture, ition emphasizes locity and variety y "2.5 quintillion e increasing each iquitous access to es. Data is created ating in real-time. regate constantly actions e.g. one of over 618 million ystem can be also are needed. primarily creates others: creating ng performance, othing else than ucts. orking site where ges. Twitter is a blend of social media, bloggin a purposeful message size r friendly: every microblog tw characters or less. This size c clever use of language, which challenging to write. This si popular social tool [4]. Ther experimental data source for market. II. Predicting Future s The stock market prediction i is dynamic in nature. To red stock market and increase th movements. To avoid the risk stock price. Figure 1: Desig velopment (IJTSRD) -ISSN: 2456 – 6470 st 2019 Page 1444 a Analytics Pathein, Myanmar ng in these days. Large datasets m and widely available stock to conduct sentiment analysis rices. The relation between mined. A comparative study of Support Vector Machine and is; Multiple Linear Regression l Neural Network (ANN) opular Investments Due To Its y An Explosion Of Data But Also ctise Reasons. Scientists And “Big Data” To Name This Trend. And Velocity. Volume Refers To Number Of Types Of Data And ng. a. One Of The Main Reason Is Sectors Of The Economy From Financial Sector. ng and texting. Twitter employs estriction to keep things scan weet entry is limited to 280 cap promotes the focused and h makes tweets easy to scan and ize restriction made Twitter a refore Twitter was chosen for r this work on predicting stock stock prices is difficult since the stock price duce the false forecasts of the he ability to predict the market k and the complex in predicting gn of the System

Upload: ijtsrd

Post on 19-Sep-2019

4 views

Category:

Education


0 download

DESCRIPTION

Prediction in the stock market is very challenging in these days. Large datasets available from Twitter micro blogging platform and widely available stock market records. Machine learning was employ to conduct sentiment analysis of data and to estimate for future stock prices. The relation between sentiments and the stock value is to be determined. A comparative study of these algorithms Multiple linear Regression, Support Vector Machine and Artificial Neural Network are done. Thin Thin Swe | Phyu Phyu | Sandar Pa Pa Thein "Predition Model for Stock Price on Big Data Analytics" Published in International Journal of Trend in Scientific Research and Development (ijtsrd), ISSN: 2456-6470, Volume-3 | Issue-5 , August 2019, URL: https://www.ijtsrd.com/papers/ijtsrd26660.pdfPaper URL: https://www.ijtsrd.com/computer-science/database/26660/predition-model-for-stock-price-on-big-data-analytics/thin-thin-swe

TRANSCRIPT

Page 1: Predition Model for Stock Price on Big Data Analytics

International Journal of Trend in Scientific Research and Development (IJTSRD)Volume 3 Issue 5, August 2019

@ IJTSRD | Unique Paper ID – IJTSRD26660

Predition Model Thin Thin Swe

Lecturer, Faculty of Information Science How to cite this paper: Thin Thin Swe | Phyu Phyu | Sandar Pa Pa Thein "Predition Model for Stock Price on Big Data Analytics" Published in International Journal of Trend in Scientific Research and Development (ijtsrd), ISSN: 2456-6470, Volume-3 | Issue-5, August 2019, pp.1444-1446, https://doi.org/10.31142/ijtsrd26660 Copyright © 2019 by author(s) and International Journal of Trend in Scientific Research and Development Journal. This is an Open Access article distributed under the terms of the Creative Commons Attribution License (CC BY 4.0) (http://creativecommons.org/licenses/by/4.0)

The Analyses Of Information That Is A ByDifferent Business Activities By Companies Can Lead To Better Understanding The Needs Of Their Customers And Preditions Future Trends. It Was Previously Reported In Several Research Papers That Precise Financial Markets A. Big Data There are several definitions what Big data is , one of them is following: "Big data refers to datasets whose size is beyond the ability of typical database software tools to capture, store, manage, and analyse." [2] This definition emphasizes key aspects of big data that are volume, velocity and variety [3]. According to IBM reports [4] everyday "2.5 quintillion bytes of data" is created. These figures are increasing each year. This is due to previously described ubiquitous access to the Internet and growing number of devices. Data is created and delivered from various systems operating in realFor example social media platforms aggregate constantly information about user activities and interactions e.g. one of most popular social sites Facebook has odaily active users [5]. Output rate of the system can be alsoimportant when nearly real-time analyses are needed. But big data is not only challenging but primarily creates opportunities. They are, among the others: creating transparency, optimization and improving performance, generation of additional profits and nothing else than discovering new ideas, services and products. B. Social Media Twitter is an online news and social networking site where people can communicate in short messages

IJTSRD26660

International Journal of Trend in Scientific Research and Development (IJTSRD)Volume 3 Issue 5, August 2019 Available Online: www.ijtsrd.com e-

26660 | Volume – 3 | Issue – 5 | July - August 2019

Predition Model for Stock Price on Big DataThin Thin Swe, Phyu Phyu, Sandar Pa Pa Thein

Faculty of Information Science, Universtiy of Computer Studies, Pathein, Myanmar

http://creativecommons.org/licenses/by

ABSTRACT Prediction in the stock market is very challenging in these daysavailable from Twitter micro blogging platform and widely available stock market records. Machine learning was employ to conduct sentiment analysis of data and to estimate for future stock prices. The relation between sentiments and the stock value is to be determined. A comparative study of these algorithms: Multiple linear Regression, Support Vector Machine and Artificial Neural Network are done.

KEYWORDS: Stock Market; Sentiment Analysis; Multiple Linear Regression (MLR); Support Vector Machine (SVM); Artificial Neural Network (ANN)

I. INTRODUCTION The Stock Market Is Always One Of The Most Popular Investments Due To Its High Profit. Recent Years Have Shown Not Only An Explosion Of Data But Also Widespread Attempts To Analyse It For Practise Reasons. Scientists And Computer Engineers Have Crated Special Term “Big Data” To Name This Trend. Main Features Of Big Data Are Volume, Variety And Velocity. Volume Refers To The Amount Of Data, Variety Refers To The Number Of Types Of Data And Velocity Refers To The Speed Of Data Processing.

There Are Many Reasons To Grow Of Big Data. One Of The Main Reason Is Computer Systems Start To Be Used In Many Sectors Of The Economy From Governments And Local Authories To Help To Financial Sector.

A By-Product Of Different Business Activities By Companies Can Lead To Better Understanding The Needs Of Their Customers And Preditions Future Trends. It Was Previously Reported In Several Research Papers That Precise Financial Markets [1].

There are several definitions what Big data is , one of them is following: "Big data refers to datasets whose size is beyond the ability of typical database software tools to capture, store, manage, and analyse." [2] This definition emphasizes

of big data that are volume, velocity and variety [3]. According to IBM reports [4] everyday "2.5 quintillion bytes of data" is created. These figures are increasing each year. This is due to previously described ubiquitous access to

ng number of devices. Data is created and delivered from various systems operating in real-time. For example social media platforms aggregate constantly information about user activities and interactions e.g. one of most popular social sites Facebook has over 618 million daily active users [5]. Output rate of the system can be also

time analyses are needed.

But big data is not only challenging but primarily creates opportunities. They are, among the others: creating

, optimization and improving performance, generation of additional profits and nothing else than discovering new ideas, services and products.

Twitter is an online news and social networking site where people can communicate in short messages. Twitter is a

blend of social media, blogging and texting. Twitter employs a purposeful message size restriction to keep things scan friendly: every microblog tweet entry is limited to 280 characters or less. This size cap promotes the focused and clever use of language, which makes tweets easy to scan and challenging to write. This size restriction made Twitter a popular social tool [4]. Therefore Twitter was chosen for experimental data source for this work on predicting stock market.

II. Predicting Future stock pricesThe stock market prediction is difficult since the stock price is dynamic in nature. To reduce the false forecasts of the stock market and increase the ability to predict the market movements. To avoid the risk and the complex in predictingstock price.

Figure 1: Design of the System

International Journal of Trend in Scientific Research and Development (IJTSRD)

-ISSN: 2456 – 6470

August 2019 Page 1444

n Big Data Analytics

Pathein, Myanmar

Prediction in the stock market is very challenging in these days. Large datasets available from Twitter micro blogging platform and widely available stock

records. Machine learning was employ to conduct sentiment analysis of data and to estimate for future stock prices. The relation between sentiments and the stock value is to be determined. A comparative study of

, Support Vector Machine and

Stock Market; Sentiment Analysis; Multiple Linear Regression (SVM); Artificial Neural Network (ANN)

The Stock Market Is Always One Of The Most Popular Investments Due To Its High Profit. Recent Years Have Shown Not Only An Explosion Of Data But Also Widespread Attempts To Analyse It For Practise Reasons. Scientists And

ial Term “Big Data” To Name This Trend. Main Features Of Big Data Are Volume, Variety And Velocity. Volume Refers To

Variety Refers To The Number Of Types Of Data And Velocity Refers To The Speed Of Data Processing.

ons To Grow Of Big Data. One Of The Main Reason Is Computer Systems Start To Be Used In Many Sectors Of The Economy From Governments And Local Authories To Help To Financial Sector.

blend of social media, blogging and texting. Twitter employs a purposeful message size restriction to keep things scan friendly: every microblog tweet entry is limited to 280 characters or less. This size cap promotes the focused and

use of language, which makes tweets easy to scan and This size restriction made Twitter a

popular social tool [4]. Therefore Twitter was chosen for experimental data source for this work on predicting stock

stock prices The stock market prediction is difficult since the stock price is dynamic in nature. To reduce the false forecasts of the stock market and increase the ability to predict the market movements. To avoid the risk and the complex in predicting

Figure 1: Design of the System

Page 2: Predition Model for Stock Price on Big Data Analytics

International Journal of Trend in Scientific Research and Development (IJTSRD)

@ IJTSRD | Unique Paper ID – IJTSRD26660

A. Data Collection and Processing The Yahoo finance data contain BSE data and NSE data. The financial index of BSE is SENSEX and for NSE is NIFTY. This finance data contain many attributes of the stock market. Some of the attributes are opening value, closing value, adjacent close value, min value, max value, volume, dividend, date and time of the day. The key attributes are selected for stock market prediction in this work. The collected data are processed by normalization and used as the input data. For monthly prediction and daily prediction historical data from Yahoo finance is used. B. Multiple Linear Regression Regression is a data mining task of predicting the stock price by implementing a model based on one orThis technique is a compact method of mathematical representation. It represents the relationship between the response parameter and the input parameter in a given prediction model. Prediction of the outcome y from the input parameter x of the form

Y = β0 + β1 x1 + β2 x2… + βk xk y – Outcome, β0 – Intercept, β1, β2, βk – Partial Regression Co-efficient, x1, x2, xk – Input Parameters. The least square value is determined by the current market price y from the PE ratio and mean of the input parameters

y = a + bx C. Support Vector Machine

In machine learning, Support vector machine is supervised learning models with associated learning algorithms to identify the data. This process includes the classification and regression methods to analyse the prediction. It implements the margins adoption to predict the market price. The support vector means the closest hyper-plane and it is equal in distance are identified. The value of support vector y is calculated using the two attribute case .

y = w0 + w1 x1 + w2 x2 y – Outcome, w0, w1, w2 – three weights to belearned by SVM model, x1, x2 – input parameters D. Artificial Neural Network

The artificial neural network is deep learning athidden layer neuron. Artificial Intelligence used to train the prediction model to identify the trends in a complicated environment. The input value is assigned withdifferent weights in the input layer. The output of the input layer is fed into the hidden layer neuron as the input. Tsummation function is evaluated in the hidden layer. It learns every prediction at each node. If any hidden layerneuron is not completed, then it is fed into the summation function.

h = ∑ wi.xi h – Summation function, ∑wi – Weight of the inputvalue. The output of the hidden layer is given as input to the output layer where the sigmoid function O is determined using the summation function h.

O = 1 / 1+e (-h)

International Journal of Trend in Scientific Research and Development (IJTSRD) @ www.ijtsrd.com

26660 | Volume – 3 | Issue – 5 | July - August 2019

The Yahoo finance data contain BSE data and NSE data. The financial index of BSE is SENSEX and for NSE is NIFTY. This finance data contain many attributes of the stock market.

e of the attributes are opening value, closing value, adjacent close value, min value, max value, volume, dividend, date and time of the day. The key attributes are selected for stock market prediction in this work. The collected data are

alization and used as the input data. For monthly prediction and daily prediction historical data from

Regression is a data mining task of predicting the stock price by implementing a model based on one or more attributes. This technique is a compact method of mathematical representation. It represents the relationship between the response parameter and the input parameter in a given prediction model. Prediction of the outcome y from the input

(1)

Partial Regression

The least square value is determined by the current market the input parameters

(2)

In machine learning, Support vector machine is supervised learning models with associated learning algorithms to identify the data. This process includes the classification and

hods to analyse the prediction. It implements the margins adoption to predict the market price. The

plane and it is equal in distance are identified. The value of support vector y is

(3)

three weights to be input parameters

The artificial neural network is deep learning at hidden layer neuron. Artificial Intelligence classifiers are used to train the prediction model to identify the trends in a complicated environment. The input value is assigned with different weights in the input layer. The output of the input layer is fed into the hidden layer neuron as the input. The summation function is evaluated in the hidden layer. It learns every prediction at each node. If any hidden layer neuron is not completed, then it is fed into the summation

(4)

Weight of the input, xi – Input

The output of the hidden layer is given as input to the output layer where the sigmoid function O is determined using the

(5)

Figure2: Process of ANN E. Sentiment Analysis The expression of each individual varies and it is analysed in social media data. The polarity of each word is evaluated. The polarity can be neutral, positive and negative. The correlation between the news and actual price is determined. The Sentiment valFor each word in a row do the Sentiment Calculation. Sent_Word (word,dictionary)Sent_Word : compare the word with dictionary. S = Sent_Word (7) S – Calculates the value of sentiment anlysis of the data. III. discussion of resultAs it can be observed from presented results,stock prices depend strongly ontheir preparation methods and number of appearing messages per time interval. Predictions conducted with models trained with datasets with messages containing company stock symbol performs better. It can be explained by the fact that these messages refer to stock market. Tweets with company name may just transfer information, which does not affect financial results. Another important factor is a choice of preparation of training set. Two methods were used. One of the methods was a manual labeling sentiment value of messages. This method allows to more accurately label training data but is not effective for creating large training sets. The other method was applying SentiWordNet, which is a lexical resource for sentiment opinion mining. It enabled to create bigger training datasets, which resulted in building more accurate models. Last factor that is important for prediction is number of appearing messages per time interval. Although model trained with datasets with company name were not accurate in comparison to the other datasets, there is bigger number of tweets per time interval. It allowed performing prediction fwhich were not possible for dataset with messages containing company stock symbol. Described methods can be also used with other stock predictions procedures in order to maintain higher accuracy. It is also important to note that stock prediction methods are not able to predict sudden events called ‘black swans’ [7] . IV. conclusions The purpose of this study is to compare the performance of the three prediction algorithms Multiple Linear Regression, Support Vector Machine, Artificiastock market. The Multiple Linear Regression

www.ijtsrd.com eISSN: 2456-6470

August 2019 Page 1445

2: Process of ANN

The expression of each individual varies and it is analysed in social media data. The polarity of each word is evaluated. The polarity can be neutral, positive and negative. The correlation between the news and actual price is determined. The Sentiment value in a row S is initial zero. For each word in a row do the Sentiment Calculation.

Sent_Word (word,dictionary) (6) Sent_Word : compare the word with dictionary.

Calculates the value of sentiment anlysis of the data.

discussion of result As it can be observed from presented results, predictions of stock prices depend strongly on choice of training dataset,

methods and number of appearing time interval. Predictions conducted with

trained with datasets with messages containing company stock symbol performs better. It can be explained by the fact that these messages refer to stock market. Tweets with company name may just transfer information, which does not affect financial results.

Another important factor is a choice of preparation of training set. Two methods were used. One of the methods was a manual labeling sentiment value of messages. This method allows to more accurately label training data but is

large training sets. The other applying SentiWordNet, which is a lexical

resource for sentiment opinion mining.

It enabled to create bigger training datasets, which resulted in building more accurate models. Last factor that is

ediction is number of appearing messages per time interval. Although model trained with datasets with company name were not accurate in comparison to the other datasets, there is bigger number of tweets per time interval. It allowed performing prediction for shorter time intervals, which were not possible for dataset with messages containing company stock symbol. Described methods can be also used with other stock predictions procedures in order to maintain higher accuracy. It is also important to

stock prediction methods are not able to predict sudden events called ‘black swans’ [7] .

The purpose of this study is to compare the performance of the three prediction algorithms Multiple Linear Regression, Support Vector Machine, Artificial Neural Network in the stock market. The Multiple Linear Regression

Page 3: Predition Model for Stock Price on Big Data Analytics

International Journal of Trend in Scientific Research and Development (IJTSRD) @ www.ijtsrd.com eISSN: 2456-6470

@ IJTSRD | Unique Paper ID – IJTSRD26660 | Volume – 3 | Issue – 5 | July - August 2019 Page 1446

algorithm is less developed state which measures the relationship between the stock price and volume. The Support Vector Machine algorithm is a two-class classifier for the learning model. The Artificial Neural Network is the classification algorithm for deep learning. The result exhibits that the deep learning algorithm performs better than the MLR and SVM. In deep learning algorithm the hidden layer neuron learns in every prediction. Hence the output layer neuron produces the best outcome. Artificial Neural Network is the best predicting algorithm. References [1] Z. Da, J. Engelberg, P. Gao: In Search of Attention,

The Journal of Finance Volume 66, Issue 5, pages 1461–1499, October 2011, doi: 10.1111/j.1540- 6261.2011.01679.x

[2] J. Manyika, M. Chui, B. Brown, J. Bughin, R. Dobbs, C. Roxburgh, and A.H. Byers. Big data: The next frontier for innovation, competition, and productivity, McKinsey, May 2011..

[3] Edd Dumbill. What is big data? : an introduction to the big data landscape. http:// radar.oreilly.com/2012/01/what-is big-data.html, 2012 R. Nicole, “Title of paper with only first word capitalized,” J. Name Stand. Abbrev., in press.

[4] What is Twitter and How does it work? http://www.lifewire.com/ what-is –twitter.

[5] Hagenau, Michael, Michael Liebmann, Markus Hedwig, and Dirk Neumann. "Automated news reading: Stock price prediction based on financial news using context-specific features." In System Science (HICSS), 2012 45th Hawaii International Conference on, pp. 1040-1049. IEEE, 2012.

[6] Khan, Zabir Haider, Tasnim Sharmin Alin, and Md Akter Hussain. "Price prediction of share market using artificial neural network (ANN)." International Journal of Computer Applications 22, no. 2 (2011): 42-47

[7] N. N. Taleb, Common Errors in the Interpretation of the Ideas of Then Black Swan and Associated Papers.