Sunteți pe pagina 1din 9

INTRODUCTION

The stock market is characterized by high-risk, high-yield, so


investors are concerned about the analysis of the stock market
and trying to forecast the trend of the stock market. Stock
market is coupled with many complexities such as price
(stock index) changes in the non-linear trend and shares data
with high noise characteristics, therefore the traditional
mathematical statistical techniques to forecast the stock
market has not yielded satisfactory results.
Neural networks can approximate any complex non-linear
relations and has robustness and fault-tolerant features.
Therefore it is very suitable for the analysis of stock data.
The aim of this paper is to use Artificial Neural Network to
forecast closing price of the stock Tata Steel.
STOCK MARKET
A stock market is a primarily a virtual exchange of securities
(shares and debentures), which companies use as a means of
raising finance and derivatives that can be traded.
Forecasting stock market return is gaining more attention,
because of the fact that if the direction of the market is
successfully predicted the investors may be better guided.

WHY ANN IS USED FOR STOCK MARKET


FORECASTING
• Stock market returns are not perfectly linear so the
residual variance between the predicted return and the
actual is quite high.
• The traditional statistical models have limitations in
understanding the non linear relationship between the
input and the output of the system because of the
complex and chaos nature of the system.
• ANN has the ability to discover nonlinear relationship in
the input data set without a prior assumption of the
knowledge of relation between the input and the output.
Discussion on forecasting methods
1.Statistical time series Methods
Time series analysis is a widely used statistical tool for
forecasting future events that are in some way related to
economy or any other fields by using the historical data as
the basis.
Methods for forecasting are:
 Moving Average
 Smoothing Methods
 Autoregressive moving average (ARMA)
 Autoregressive integrated moving average (ARIMA)
Method used in the paper: ARIMA: It is a class of linear
models which has the capability of representing stationary as
well as non-stationary data. In ARIMA or ARMA, the time
series is analysed to find the parameters (p,q) by the patterns
of autocorrelation and partial autocorrelation and using these
parameters future values are predicted. ARIMA totally depend
on autocorrelation in the data.
MEASURES OF FORECASTING ACCURACY
The forecast error is the difference between the actual value
and the forecast value for the corresponding period. et = Yt -
Ỹt

MAPE (1/𝑛) ∑ ∣Yt - Ỹt ∣ / Yt & MSE (1/𝑛) ∑ ( Yt - Ỹt )2


for t=1,...,n are the commonly used.
2. ARTIFICIAL NEURAL NETWORK
APPROACH
 An Artificial Neural Network (ANN), is a mathematical
or computational model that is inspired by the structure
or functional aspects of biological neural networks.

 A neural network consists of an interconnected group of


artificial neurons, and it processes information using a
connectionist approach to computation.

Training Algorithm: Training is the process by which the free


parameters of the networks (i.e. the weights) get optimal values.
MATHEMATICAL MODEL OF ANN
OBJECTIVE OF THE PAPER
To forecast the closing price of the stock market by statistical
method and by artificial neural network and to compare the
results these two methods.

DATA SET
The data set consists of closing prices of Tata Steel stock of
the trading days from 3rd January 2005 to 1st April 2008. The
data is collected from the historical data available on the
website of BSE.

METHODOLOGY AND RESULTS


Results from ARIMA: Time series plot of the closing prices
of TATA STEEL Stock having an upward trend so it is a non-
stationary graph

TIME SERIES PLOT OF CLOSING PRICES OF TATA STEEL


1000

900

800

700
CLOSING PRICE

600

500

400

300

200

100
1 10 20 30 40 50 60 70 80 90
Index
Autocorrelation Function for CLOSING PRICE
(with 5% significance limits for the autocorrelations)

1.0
0.8
0.6
0.4
Autocorrelation

0.2
0.0
-0.2
-0.4
-0.6
-0.8
-1.0

2 4 6 8 10 12 14 16 18 20
Lag

Partial Autocorrelation Function for CLOSING PRICE


(with 5% significance limits for the partial autocorrelations)

1.0
0.8
0.6
Partial Autocorrelation

0.4
0.2
0.0
-0.2
-0.4
-0.6
-0.8
-1.0

2 4 6 8 10 12 14 16 18 20
Lag

Plot for autocorrelation and partial autocorrelation function of


closing prices indicating that time series is non stationary.
TIME SERIES PLOT AFTER DIFFERENCING
150

100

50
DIFFERENCES

-50

-100

1 8 16 24 32 40 48 56 64 72 80
Index

1st order differencing to remove the non-stationarity. Then the


series become stationary.
Autocorrelation Function for DIFFERENCES
(with 5% significance limits for the autocorrelations)

1.0
0.8
0.6
0.4
Autocorrelation

0.2
0.0
-0.2
-0.4
-0.6
-0.8
-1.0

2 4 6 8 10 12 14 16 18 20
Lag

ACF of Residuals for CLOSING PRICE


(with 5% significance limits for the autocorrelations)

1.0
0.8
0.6
0.4
Autocorrelation

0.2
0.0
-0.2
-0.4
-0.6
-0.8
-1.0

2 4 6 8 10 12 14 16 18 20
Lag
DIFFERENT MODELS PARAMETERS AND
MINITAB OUTPUT
1. Moving Average Method [MA(1,1,0)] , MSE = 2825
2. Autoregressive Method [AR(0,1,1)] , MSE = 2828
3. ARIMA [ARIMA(1,1,1)] ,MSE = 2691

RESULTS FROM ANN:


Performance = 9.2605e-08
TrainPerformance = 4.1453e-08
valPerformance = 2.6442e-07
TestPerformance = 1.5268e-07
perfc = 2.1144e-06
closedLoopPerformance = 2.1144e-06

COMPARISON OF RESULTS:
Here in both the methods MSE is calculated and compared
which shows that MSE of ANN is less than ARIMA method.
ARIMA ANN
MSE √(2691) = 51.87 5.63580e-1 =
0.0379

CONCLUSION: Three models from statistics and one from


artificial neural network were used to check the result and
they are compared on basis of the MSE. The ANN outperform
the statistical techniques in forecasting stock market prices.
Based on the findings of this study it can be concluded that
the prediction models based on ANNs were more accurate
than the ones based on moving averages and ARIMA models.
ACKNOWLEDGEMENT

I express my deep gratitude to Dr.(Mrs.) Kajla Basu (Associate


Professor) NIT Durgapur my project guide for her priceless
guidance and encouragement to give this project a unique
outlook.

REFERENCES

1. Bogazici University, Hisar Kampus, Stock Market Prediction


Using Artificial Neural Networks.

2. Ramon Lawrence , Department of Computer Science, University of


Manitoba, Using Neural Networks to Forecast Stock Market
Prices.

3. BENARD, W., DAVID, E.R. and MICHAEL, A.L., Neural


Networks Applications in Industry, Business and Science,
COMMUNICATIONS OF THE ACM, Vol. 37, No. 3, 1994, pp.
313-333.

4. KAMOJO, K. and TANIGAWA, T., Stock Price Pattern


Recognition- A Recurrent Neural Network Approach, Proceedings
of the 1990 International Joint Conference on Neural Networks,
1990, pp. 1/215-1/221.

5. Manna Majumdar, Proffesional Banker, MD Anwar Hussain


Professor North East Regional Institute of Science and Technology

S-ar putea să vă placă și