Professional Documents
Culture Documents
Machine Learning Thesis (En)
Machine Learning Thesis (En)
Arranged by:
NIM : 17523229
2021
Machine Translated by Google
ii
THESIS
Arranged by:
NIM : 17523229
iv
Machine Translated by Google
PRIVATE PAGE
compiling this final project research. With all the processes and struggles faced, I
would like to thank several parties, namely my beloved mother, brother
my brothers who always give advice, my friends who faithfully support
in times of joy and sorrow, comrades in arms, Mr. Dhomas Hatta Fudholi, ST,
M.Eng., Ph.D. as supervising lecturer, and the Department of Informatics at the Islamic University of Indonesia
where do i study
Machine Translated by Google
vi
MOTO PAGE
“When will someone die? When he got shot? No! When he was poisoned
turn off? No! When he ate poisoned food? No! Someone will die
“Dreams are not something you see while sleeping, but something you make
you can't sleep”
-Cristiano Ronaldo
"Whoever goes out seeking knowledge, then he is in the way of Allah until he returns"
- HR Tirmidhi
Machine Translated by Google
vii
FOREWORD
Alhamdulillah, all praise and gratitude I say to the presence of Allah SWT, who has
give her pleasure and mercy. So that the author can complete the final report
is entitled "Predicting the Trend of Stock Price Movements Using the Temporal Algorithm
Convolutional Network (TCN)” which is part of my worship to Allah SWT.
This report is prepared to fulfill the final task as a condition for completion
education at the level of Strata 1 (S1) in the Department of Informatics at the Indonesian Islamic University.
The author realizes that this report will not be completed quickly without support
and motivation from various parties. For this reason, the author does not forget to express his gratitude
2. My beloved mother, Sri Rejeki, SE who gives all the support and love
love me.
3. Mr. Fathul Wahid, ST, M.Sc., Ph.D. as Chancellor of the Indonesian Islamic University
4. Mr Prof. Dr. Ir. Hari Purnomo, MT as the Dean of the Faculty of Industrial Technology
Indonesian Islamic University.
5. Mr. Hendrik, ST, M.Eng. as Chair of the Department of Informatics at the Islamic University
Indonesia.
6. Mr. Raden Teduh Dirgahayu, ST, M.Sc., as Chair of the Informatics Study Program
Undergraduate Program in the Faculty of Industrial Technology, Islamic University of Indonesia.
7. Mr. Dhomas Hatta Fudholi, ST, M.Eng., Ph.D. as the assignment supervisor
which provides direction in the preparation of the final report.
8. Mr. and Mrs. lecturers of the Informatics Study Program, who have provided the knowledge
has educated and imparted his knowledge during my studies.
9. Brothers, friends, and my friends who always provide support when
state of joy and sorrow.
Hopefully all parties who provide assistance, support, guidance, and prayers
given to the author to get the goodness of Allah SWT. The author apologizes
if during the process of working on the final report there are oversights and errors. Writer
Machine Translated by Google
viii
Hopefully, this final project report can be useful for the world of education and
development of informatics and technology.
ix
SARI
for those used for future plans or multiplying its value. One of
The most popular financial instrument among Indonesian people is stocks. Whereas
Understanding own shares according to the Indonesian Stock Exchange (IDX), shares are a sign of participation
trends in stock price movements in addition to paying attention to company fundamentals and reading
stock price charts, can take advantage of artificial intelligence technology , especially deep
learning. In this study used the Temporal Convolutional deep learning algorithm
Network (TCN) which uses the convolution concept to predict movement trends
stock prices utilize the Darts library which was developed to process time data
series, the stock data used are shares from Netflix, Inc (NFLX). Results that
obtained, TCN is able to provide predictive results that outperform some algorithms
others such as Long Short Term Memory (LSTM), Linear Regression, and Decision Tree
Regression. With the calculated value of Root Mean Squared Error (RMSE), TCN gets
value 9,865, LSTM 10,710, Lineaer Regression 11,894, and Decision Tree Regression 30,868.
It can be seen that the TCN algorithm is quite effective for predicting price movement trends
GLOSSARY
Pre-processing the stages of preparing data so that it can be processed in the algorithmic model
.
Machine Translated by Google
xi
LIST OF CONTENTS
TITLE PAGE…………………………………………………………………………...i
PRESENTATION PAGE……………………………………………………………………….v
MOTO PAGE…………………………………………………………………………..vi
PREFACE……………………………………………………………………………….. vii
SARI…………………………………………………………………………………………………..ix
GLOSSARY……………………………………………………………………………….... x
LIST OF CONTENTS…………………………………………………………………………………. xi
LIST OF FIGURES………………………………………………………………………...xiv
CHAPTER I INTRODUCTION…………………………………………………………….. 1
1.1 Background…………………………………………………………………....1
1.2 Problem Formulation………………………………………………………………...3
2.1.3 News…………………………………………………………………….. 13
2.2 Netflix………………………………………………………………………….... 14
Learning…………………………………………………………...18
xi
CHAPTER V CLOSING……………………………………………………………………………71
5.1 Conclusion…………………………………………………………………….... 71
5.2 Suggestions…………………………………………………………………………….. 71
REFERENCES………………………………………………………………………... 73
ATTACHMENT…………………………………………………………………………………. 77
Machine Translated by Google
xiii
LIST OF TABLES
xiv
LIST OF FIGURES
Figure 2.1 Please copy and paste to create an image title ............................................... ........3
Figure 2.2 How to copy and paste equation ( 3.1 ) into equation ( 2.1 )................................5
Figure 2.5 Support and resistance areas for NFLX stocks................................................. ........11
Figure 3.2 Flowchart of the Temporal Convolutional Network (TCN) model ….................................32
Figure 3.3 Flowchart of the Long Short Term Memory (LSTM) model ….................................33
Figure 3.4 Flowchart of the Linear Regression model and Regression Decision Tree ..................34
xv
Figure 4.24 Building the LSTM model and training process................................................. ......49
Figure 4.38 Dividing the dataset into training and testing data ................................................. .56
xvi
Figure 4.46 The function for displaying the LSTM visualization................................................. .......60
Figure 4.47 Visualization of predictions for the LSTM model as a whole ...............................................61
Figure 4.52 Function for displaying the visualization of the Decision Tree model.................................64
Figure 4.53 Visualization of the overall prediction of the Decision Tree model .........................64
Figure 4.54 Visualization of the predictions of the Decision Tree model in detail.............................65
PIG
INTRODUCTION
1.1 Background
Access to information that is getting easier opens the way for the financial world to be increasingly recognized by
society at large. The community is increasingly understanding the importance of asset management
is dominated by the younger generation under 30 years of age with a percentage of 57.40%.
(CNBC Indonesia, 2021). This significant growth is one
the positive impact due to the Covid-19 pandemic, people are moving their assets to
investment instrument to maintain its value. Even though at the beginning of the pandemic the Stock Price Index
The Composite Index (IHSG), which had experienced a correction, reached 32%. Besides that, a lot
fintech companies that provide investment platforms make it easier for the public
to start investing.
Not only in Indonesia, the US stock market also experienced an impact
as a result of the Covid-19 pandemic. Positive cases of Covid-19 in the United States alone
is the highest in the world reaching 18 million cases by the end of 2020
based on data from Johns Hopkins University which is very influential on the situation
many large companies have their shares on the American stock exchange. But after experiencing
correction at the start of the pandemic, in the second half of 2020 stocks in the S&P 500 index
and the Nasdaq began to strengthen beyond the price before experiencing a correction that was accompanied by
development of the production of the Covid-19 vaccine. The S&P 500 Index closed up 0.5% percent,
while the Nasdaq index of shares of technology companies closed up 0.95%. However
the Dow Jones index of industrial stocks closed below its pre-slump price
by 0.3%. Technology companies benefiting society
who should stay at home like Amazon, Netflix, and FedEx are leading the recovery
happened and even FedEx stock is the best performing stock on the S&P index
500 (Ika Ramadhani, 2020).
Machine Translated by Google
.While the definition of shares themselves according to the Indonesian Stock Exchange (IDX), shares are
company, claims on company assets, and has the right to attend the General Meeting of Shareholders
Shares (GMS) (IDX, nd). These tokens can later be traded on the stock exchange
However, as a company's shares are released to the public and are traded on
stock exchange, the share price will fluctuate. Internal and external factors can
affect the stock price (Zainuddin & Hartono, 1999). Internal factors can
seen from the performance of the company that issued the shares, the company's performance can be
seen from the company's financial statements. While external factors are the impact of
environment outside the company that can affect directly or indirectly
direct. Which includes the economic conditions in which the company is located, social conditions
and the politics of the country. In addition investors must understand the law of demand as well
deals that occur on the stock exchange, understanding this can help investors to
determine trend predictions of stock price movements (Kusumodestoni & Sarwido, 2017). With
Knowing the trend of stock price movements, investors can use it to
To predict the trend of stock price movements in addition to paying attention to fundamentals
companies and reading stock price charts, can take advantage of artificial technology
The concept of machine learning is to try to imitate how the human brain works,
the machine is trained using certain algorithms to learn from complex data and
information or patterns from these data (Karno, 2020). Information that has been obtained
later it will be used to predict patterns from data that will occur in the future
stock data.
In its utilization, the data that can be processed in deep learning models is very diverse.
data used. The stock data itself has a time series data type, where each
Machine Translated by Google
data is recorded based on time and the data has an attachment to the data
previously recorded. Then the results of the predictions will be used to update the data
used for learning (Karno, 2020). Data with characteristics
can be processed using the Recurrent Neural Network (RNN) algorithm. Algorithm
RNN is designed to process sequentially by utilizing memory for storing
data that has been pre-processed which makes it possible to recognize patterns from data with
good (Olah, 2015). In this research, we will try to find a machine algorithm model
learning or deep learning to predict trends in stock price movements, especially
will focus on the Temporal Convolutional Network (TCN) algorithm. Based on
research carried out by (Bai et al., 2018) the TCN algorithm which utilizes the
convolution shows more accurate results than algorithms such as LSTM and GRU
in processing sequential data, and the architecture formed is simpler and clearer.
The stock data that will be used is the stock data from Netflix, Inc (NFLX), because
during the Covid-19 pandemic, Netflix was one of the services that was affected
positive. With the company's revenue increasing to reach 24% at the end
quarter of 2020 according to data from (money.kompas.com, 2021), so the stock is attractive
to analyze and predict.
From the background that has been described previously, the formulation of the problem is:
as follows:
a. How to build and evaluate the Temporal Convolutional algorithm
Network (TCN) in predicting the trend of stock price movements?
b. Comparing the performance of the Temporal Convolutional Network (TCN) algorithm with
another algorithm in the case of predicting stock price movements.
and other algorithms, it is hoped that the algorithm that gets good performance can
used to predict the trend of stock price movements in the stock market.
a. The model developed in this study is only for one stock issuer, namely
c. Comparison of prediction results based on values obtained from Root Mean Squared
Errors (RMSE).
a. Literature study, the first stage to be carried out is the search for the problem you want
research that has been done before as well as from problems that occur in
around. Literature study was conducted with the aim of knowing the state of the art of research
selected. Data obtained from the Yahoo Finance website, the range of data taken
c. Data processing, after stock data is obtained then the data must be processed first
e. The training and testing process, after the machine learning algorithm model is complete
built then the data is entered in the model and the training process is carried out.
The model that has completed the training process will then be tested
measurement error that occurs. Next will be compared and analyzed with
In the systematics of writing, the writing is divided into five chapters, namely as follows:
Chapter I Introduction
previously carried out on the theme raised in this study, which will
used as a reference.
This chapter contains the results of the research that has been done,
problems that occur in research and analysis of the results that have been
obtained.
Machine Translated by Google
CHAPTER V Closing
This chapter contains the conclusions of the research that has been done as well
CHAPTER II
THEORETICAL BASIS
that would want to invest. There are many considerations that must be taken carefully
by investors, in order to get companies that have good prospects and stock prices
best (Filbert, 2020). As you know, stock price movements are very volatile
Therefore stocks are classified as investment instruments with very high risk.
Even so, in line with the risks borne, the potential benefits are obtained
also getting bigger. With the right analysis, this potential can be exploited by
financial statements issued by companies listed on the stock exchange with a view
sides: Profitability (profit), Solvability (company liabilities and assets), Liquidity (ability
pay off debts), and Activity (business continuity) (Filbert, 2020a). Apart from the internal side
company, seen also from the external side related to the corporate sector
etc. The results of the analysis produce an assessment of whether the company's shares
is worth buying or not. If the conclusions obtained are considered stock prices
too expensive compared to its fair price based on the value of the company, then shares
recommended for sale rather than buying it. Meanwhile if that happened
otherwise, the shares are recommended to be purchased (Agusta Nanda et al., 2016).
published quarterly or annually. Then the assessment will be updated every time there is
new financial report issue. However, the problem is that investors often lack
precise timing when making decisions. For this reason, investors can see price movements
Technical analysis is an analysis of the historical movement of stock prices in the form of prices
opening, closing price, highest price, lowest price, and trading volume on
certain period presented in graphical form (Filbert, 2020). To observe the chart
This stock price movement requires a charting application that is usually provided
by the stock broker chosen to make the investment. Technical analysis is more used
to observe price trends that are happening and within these trends there are patterns
simplified and comprehensive information about current stock prices (Suresh, 2013).
Technical analysis itself was first put forward by Charles Henry Dow in
early 19th century whose name is now used in the name of the industrial stock index in America
namely the Dow Jones Industrial Average (DJIA). The theory explains that price movements
90% stock is influenced by psychological factors and 10% logical factors. Prices are determined by
the market participants themselves, whether it is considered too expensive or cheap. dow theory
only explains the direction of trend movement and does not predict future prices. Theory
that stock prices follow the underlying business (Suresh, 2013). Here are a few
Market Trends
Trends are the tendency for stock prices to move in a certain direction
a span of time (Hafizah et al., 2019). There are three trends in stock trading, namely,
uptrend (increasing trend) when the demand for the stock is more than the supply then
increase, when the demand for the stock is less than the supply. And trend
sideways (consolidation) that is when the price is looking for the direction of the next usual trend
occurs after an uptrend and a downtrend. Figure 2.1 shows the trend in price
stock chart form, a trend is formed by rising and falling phases. trend
bulls occur when the price forms higher troughs and peaks. trend
decline when the price forms lower troughs and peaks. While trend
In the formation of a trend, it can be divided into four basic phases so that it is formed
a price movement (Filbert, 2020a). In the first phase is the climbing phase or
reversals, in this phase are usually accompanied by news that does not support
market situation. The second phase is the bullish phase, investors start to enter and cause prices
started to increase. Furthermore, the third phase is the saturation phase, where the price is considered
is too high so it is considered less attractive to buy. The last is the phase
reversal, the price experienced a reversal of the direction of the original trend. These phases occur
In fact, the trend of stock price movement itself is a representation of the taking
the decision of investor psychology is influenced by the emotion of "fear and greed" (R Tristia, 2019).
That is, when investors experience the emotion of fear or fear, they will tend to
sell their assets for fear that the price will fall further, causing the price to drop
in the market will fall further. Conversely, when investors are too greedy or greedy
to buy assets that are experiencing price increases, so that asset prices will increase
experienced an increase and did not rule out buying at the current price
psychological factor that can dominate in decision making, the fall in prices
stocks often occur due to excessive market reactions (Lestari & Pranyoto, 2015).
Machine Translated by Google
10
Charts
11
12
13
Indicator
Apart from using the traditional way of analyzing stock price trend movements,
can also apply modern technical analysis that utilizes stock price indicators.
Indicators on stock price movements are tools that are used to help
determine movement trends (Hafizah et al., 2019). There are two types of indicators, the first
is a trend following indicator that aims to follow the trend of stock price movements
the. Trend following indicators are formed more slowly than price movements and
located attached to the chart. And the second is an oscillator indicator that shows
the level of a stock price is already in a state of overbought (over bought) or oversold (over
bought) (Pramudya & Pramudya, 2020). The occillator indicator itself is an indicator that
moves ahead of price movements and is located separately from the chart (Ahmar, 2018).
2.1.3 News
Apart from analyzing fundamentally and technically, you can also take advantage of the news
sentiment analysis. Stocks are very sensitive to the news circulating because
investors can experience panic over the sentiment that is formed is negative,
14
with Fear, Uncertainly, and Doubt (FUD). Conversely, if the resulting sentiment is
2.2 Netflix
Netflix is a paid streaming platform from the United States that provides
wide selection of movies and TV series. These services can be enjoyed through various
devices such as smart TVs, smartphones, tablets, PCs, game consoles, and laptops. Company
Netflix, Inc. founded by Marc Randolph and Reed Hastings in 1997 in Los Galtos,
physically which can be ordered online. The following year, Netflix started
shifting its business strategy into a subscription system to enjoy its services.
Customers pay a subscription fee and are free to rent the various DVDs available, and
to conduct an Initial Public Offering (IPO) on the American stock exchange, the National Association
of Securities Dealers Automated Quotation (NASDAQ) with the stock name “NFLX”. Netflix
enjoy the service through his personal computer directly. In addition to expanding
In terms of business scope, Netflix began to open various partnerships with companies
technology companies such as Xbox, Apple, Playstation, Blue-ray disc players with the goal of being
its services can be enjoyed on various devices connected to the internet. In 2013
Netflix records that it has 31 million subscribers. Not only in the United States,
Netflix doesn't have annoying ads, because it's a paid service. Customers can
enjoy watching whatever they want anytime and anywhere without having to
adhering to schedules and being interrupted by advertisements. Now, the streaming service Netflix is one
who have been positively affected by the ongoing Covid-19 pandemic. Covid-19 pandemic
15
Netflix due to the need for entertainment services to accompany people during
pandemic. Based on data (money.kompas.com, 2021) new Netflix subscribers are registered
experienced an increase of 30%, namely as many as 37 million new users, the majority
are outside the United States. The company's revenue also increased by
24% in the final quarter of 2020, revenue of 6.6 billion US dollars was recorded with
profit of 524 million US dollars .
16
17
acquire intelligence through the stages of training (training) and testing (testing) (Huang et
al., 2006). The more often a machine is trained and tested, the smarter it will be and
the ability to recognize more accurate guard information. Knowledge used on
machine learning is more towards math and statistics. Like a math formula,
machine learning is used according to the problems encountered and the data
used.
Machine learning itself can be divided into three categories, namely: Supervised lLearning,
Unsupervised Learning and Reinforcement Learning (Roihan et al., 2019). Figure 2.6
shows the division of categories in machine learning.
18
19
The way a unit of neurons works is like a human neural network, neurons will
receive input data in the form of independent variables (X 1, X2, X3, …, Xn). Then input data
on neurons there are weights in the form of (W1, W2, W3, …, Wn) which are connected to each other
every node. Then the input data and weight will be processed mathematically
using an activation function. The results of the process will then be compared
with a threshold value (threshold), if the result exceeds the threshold value then the neuron will
activated and information is passed on to the next neuron via its output weights and
so rival. If not, these neurons will not be active and information will not be received
next. Neurons will be arranged in a layer (layer) which contains many neurons.
Each of these layers will be interconnected with other layers before and after it,
except for the input layer and output layer. Connections between layers are connected to each neuron,
so a neuron will be connected to all neurons in the layer before and after it. On
a layer, the weight of each neuron will have the same value. Structure on artificial
Neural networks can be distinguished according to the number of layers contained in the network.
20
The simplest, there is a single layer neural network structure that is only
It has a single layer, namely the input layer and output layer only. Each neuron in the input layer
directly connected to the output layer, this network structure only accepts input later
processed directly into output results. Then there is a multiple layer neural structure
network, in this structure there are input layers, output layers, and hidden layers. On hidden
this layer can be set how much depends on the complexity of the problem
faced. Algorithms that use structures like this are called algorithms
deep learning, because layers are used so much that the learning process will
deeper and more complex.
21
repeated (Herlambang, 2019). For this reason, the Temporal Convolutional algorithm was introduced
a. The convolution process in the TCN architecture is causal, meaning there is no "leakage"
b. The architecture can process any length of data and will produce output
Before discussing the architecture of the Temporal Convolutional Network (TCN), it is necessary
understood about problems in sequential data modeling or commonly called time series.
With the following input data X = ( 0, 1, 2, …, T) and try to predict the output
T, can only use previously observed input data (Wan et al., 2019).
(2.1)
future input data such as T+1. The goal of sequence modeling is to search
network that minimizes some differences between the actual output data and the results
prediction. Where the target output is then used as input data for predictions
next, and continuously shift towards the next data by time step (Bai et al., 2018)
The 1 dimensional convolutional network process is a convolution process that is carried out
on data that has only one dimension such as sequential data. Tensor input data form
the same tensor output data as well namely (batch_size, input_length, output_size). Because every
layers in the TCN architecture have the same input and output length, so only input and
Machine Translated by Google
22
only the tensor output is different. Since it is only one dimension, the value of input_size and
Each convolution process will take place in every data on all of the tensor inputs .
In the picture, the kernel size is three, so the process will be carried out every three data.
The kernel has the same weight on every running process. It can be seen that each
one data in the tensor output is the result of a dot calculation from the kernel on the tensor input.
The process continues the same as the kernel will start moving towards the next data each time
one record. But to be able to get the same length of data on the input and output of the tensor
need to add zero-value padding at the beginning and end of the data.
It was mentioned earlier that TCN cannot use information from the future
the prediction uses causal convolution that is using only the current data and the data
padding with zero values at the beginning and end of the tensor input data, to calculate the amount of padding
23
(2.2)
Where:
= Number of paddings
= Kernel size
Can be seen in Figures 2.12 a and b, the difference is when using the causal process
convolutions and no. In figure c, there are four data and sizes used
The convolution process on the first data is using the two previous data, namely padding,
to get the output of the first data, and the same thing applies to
the next data so that the tensor output data has the same length as the input data.
The process of convolution on the input data which will later produce the output data, the result
depending on the kernel used and previous data. Suppose the length of the input data
is 5 with kernel size is 3, then the 5th data will depend heavily on the ke data
3 and 4. For that to avoid dependence on the data the model is able to capture
adding more layers in the network and extending the reach of the kernel on the layer
next by passing some data. That is, the output data must be connected to the data
input data from the very distant past. dilated convolution can be defined as
following:
Machine Translated by Google
24
(2.3)
Where d is the value of the dilation, k is the value of the kernel and s-dxi indicates
steps taken backwards. To calculate how many layers are needed,
and calculating the receptive field can use the formula:
(2.4)
(2.5)
Where:
ÿ= Number of layers
ÿ = Data length
= Kernel size
In Figure 2.13 you can see an example of using dilated convolution with length
data is 4, kernel size is 3, dilation value is 2, and traversed data range
is 5. If there is no dilatation process, the range of data traversed is the same as the size
the kernel is 3, whereas if it experiences a dilatation process the data range widens to 5.
However, if the dilatation value remains constant, a very long data layer will be required
next. For this reason, in the next layer , the dilatation value will increase incrementally
exponential is shown in figure 2.14, the dilation base constant represented
Machine Translated by Google
25
with ÿ and the calculation is shown in the formula. In Figure 2.14 the length is used
data is 10, kernel size is 3, dilation base is 2, and the number of layers is 3.
In practice the value of the kernel must be greater than the dilatation base. And also impact
the amount of padding will increase for each layer so a formula is needed
new namely:
(2.6)
(2.7)
In a simple TCN architecture, each layer will be interconnected with other layers ,
whereas if you use residual connection data it can be channeled directly without having to
through various layers (Wang et al., 2020). Figure 2.15 shows the difference in structure
TCN before added residual connection and after.
26
In Figure 2.15, the kernel size is 3 and the dilation value is 2. Can
Look at the changes after adding the residual connection, the output results from both layers
will later be added to the input of the residual block to produce input
on the next block . Due to the convolution process in the first layer of the residual block
first and convolution processes in the second layer of the residual block the last may have
the length of the input data is different, then the length of the residual block must be adjusted accordingly
1x1 convolution process. Adding residual blocks to the TCN architecture makes more
more ranges of data traversed than the usual model. The changes are required
Recalculate how many layers are needed to cover the value
all data. So the data range with dilatation base ÿ, kernel size with ÿ ÿ, and number
(2.8)
(2.9)
27
Figure 2.17 shows the final model of the Temporal Convolutional algorithm
Network (TCN). Where l is the data length, k is the kernel size, b is the
dilatation base with k ÿ b, the minimum number of residual blocks is n.
28
To determine the level of accuracy of the prediction results obtained by the machine model
learning can use evaluation matrices. Please note that in machine modeling
learning itself can be divided into two types, namely classification and regression modeling.
machine learning by carrying out the process of identifying data to find something
relationships (Suyanto, 2018). The evaluation process in classification modeling can generally be
using an evaluation matrix with a confusion matrix that is calculating the level of accuracy of
model, while for regression modeling can use the Root Mean evaluation matrix
Squared Error (RMSE), namely by calculating the difference between the predicted value and the actual value.
The smaller the RMSE value generated from an algorithm, the smaller the amka value
the error or the difference between the predicted value and the actual value is very small.
Mean Absolute Error (MAE) is an evaluation matrix that calculates absolute values
from the average difference between the predicted value and the actual value. The formula of MAE itself is defined
as follows:
(2.10)
Where:
N = Number of data
uses a quadratic process to calculate the error value. Formula from MSE itself
defined as follows:
Machine Translated by Google
29
(2.11)
(2.12)
There are 7 research journals that are used as references in the planning process
in this research. Related studies are presented in tabular form
makes it easy to see the results and solutions offered on predicting trend movements
stock price.
30
temporal
(Bai et Convolutional
4. al., 2018) network - Introducing the permissions of the Temporal
Convolutional Network (TCN) algorithm.
(TCN)
multivariate cases
Combination
Combines the TCN algorithm with representative
temporal
Convolutional learning called Stock2Vec. This is done
(Wang et Stock to find out the relationship between shares with
network
7. al., 2020) index one another. The results obtained were quite
(TCN) and S&P 500 good with an RMSE value of 2.22.
representatives
Learning
From the related studies that have been mentioned, predict the trend of movement
Many stock prices are developed using the Long Short Term Memory algorithm
(LSTM). However, in the LSTM algorithm itself or the development algorithm from LSTM
there are still many problems with the vanishing gradient. For this reason, the research conducted
Machine Translated by Google
31
(TCN). TCN itself has several advantages compared to LSTM, namely using
backpropagation process to minimize the occurrence of vanishing gradients and is capable
process data in parallel so that long data can be executed quickly.
But data processing using TCN requires a larger storage time
carry out the evaluation process. TCN Algorithm Able to provide good and capable results
outperforms commonly used algorithms, shown in research (Bai et al., 2018)
namely LSTM, RNN, and Gated Recurrent Unit (GRU).
For this reason, this study was chosen to use the TCN algorithm because it is based on
Recent studies are showing that TCN gives better results though
use a different approach. The results obtained by TCN are strongly influenced by
the length of the processed data, while LSTM and GRU with the same length of data
the results are variable. LSTM accuracy can drop to 20% for data below 50,
while GRU drops to 20% for data below 200. With these results, you can
demonstrated that TCN is capable of processing long data and retaining history
more distant data (Bai et al., 2018). The TCN algorithm can also be modified for
various needs according to the problem at hand, such as combining with base
knowledge to determine the correlation between data as in research (Wang et al.,
2020). This research will try to compare the performance of the TCN algorithm with
LSTM algorithm as an algorithm that is quite widely used to predict prices
stocks, Linear Regression algorithms and Decision Tree Regression which are rarely used
to predict stock prices. As well as modeling the TCN algorithm using the library
quite recently developed namely Darts.
Machine Translated by Google
32
CHAPTER III
RESEARCH METHODOLOGY
the NASDAQ-100 stock index, which has a very large market cap and
high liquidity so that the share price is not easy to manipulate and occur
sudden extreme price spikes. NFLX stock price movements are representative
various trends that occur, such as an uptrend, a downward trend, and a consolidation trend. No
rule out the possibility of using other stock data, every stock price is certain
formed from a combination of these three trends, but there is also stock price data that
the price has not experienced significant movement in a long period of time
and even the price is sprawl. For this reason, stocks that have fluctuating prices are selected
represent trend movements so that the built model can identify patterns
secondary, namely data that is not obtained directly by researchers but data that has been
world of finance namely Yahoo Finance. The data is arranged in a daily timeframe, namely data
listed every day on the exchange day (Monday-Friday). Stock data in one year
an average of 252 to 253, not a full 365 days because there are holidays on the exchange.
The range of stock data used is from 1 January 2015 to 31 May 2021, with
the amount of data is 1613 and there are 6 columns, namely the opening price (open), closing price
(close), lowest price (low), highest price (high), transaction volume, and adj close. On
This research will only use the closing price (close), because on the stock exchange day the price
will experience fluctuations, the closing price is used which is the last price
on the exchange day. Then data with daily timeframes are used because of predictions
trends to be done to know the big picture of trends and predictions will be
used for medium term investment. The data is retrieved using the pandas data library
reader, simply by entering information about the stock ticker , data source, and
33
a. Literature study was conducted to find out the latest research and state of the art from
problem to be raised.
b. The formulation of the problem is done to determine the problems encountered in the
research, and then carried out research design.
c. The first step taken is to retrieve Netflix stock data (NFLX)
which has been provided by the Yahoo Finance website. Data can be retrieved with
Utilize the library from Pandas, namely Pandas Data Reader. By using
library , the data retrieval process becomes easier, just by
Machine Translated by Google
34
enter the ticker of the desired stock then the data source and
the desired data range by setting start and end dates.
d. The next step is preprocessing the stock data that has been obtained. Process
The first thing to do in preprocessing is Exploratory Data Analysis
(EDA). Namely conducting an investigative process to understand the condition of the data
used and prepare the data so that it can be processed by the algorithm model. A number of
the process carried out is: checking the dimensions and amount of data, checking the type
h. The last process in the preprocessing stage is to split the data into
data training and data testing. Training data is used as data to perform
learning on algorithm models. And data testing is used to test
trained models.
i. The next step is to model the algorithm used.
j. The training process is carried out to carry out learning on the algorithm model.
k. Next, the model will be tested to find out the prediction results
which is conducted.
l. The prediction results will be visualized to find out how they compare
at actual prices.
m. The results of the prediction with the actual price will be calculated to get the error value
conclusion whether the model produces good or bad predictions.
n. The results of the calculation of the error value obtained will then be compared
with the error value of another algorithm. Which algorithm gets
the best and the worst results. And what things will be evaluated
causes the algorithm model to get such predictive results.
o. After the results of predictions and calculations of errors between algorithms are obtained, it will be
35
a. Building the TCN algorithm model utilizing the darts library, the data already exists
c. The backtesting process is carried out to evaluate the performance of the model using
the most popular and commonly used algorithms are used in problem solving
stock price prediction, namely the Long Short Term Memory (LSTM) algorithm. And two algorithms
The most common and simple used in machine learning models, namely algorithms
Linear Regression and Decision Tree Regression. The following is a research flowchart on
36
Figure 3.3 Flowchart of the Long Short Term Memory (LSTM) model
starting from index data 0 to 59, and 1 data starting from index 60. So
predictions will be made once every 60 data with the prediction results of the 61st data,
then the prediction will continue again from index data 1 to 60 and results
c. Changing data that is still in the form of numpy into array data .
d. Then build the LSTM model with a three- layer configuration, with layers
the first layer has 50 neurons, the second layer has 50 neurons, and the last layer
with 25 neurons.
e. Compile the model that has been built, and add functions
optimizer adam.
f. The training process on the LSTM model and setting up the available hyperparameters .
g. The process of testing the LSTM model and setting up the available hyperparameters .
Machine Translated by Google
37
Explanation of the Linear Regression and Decission Tree Regression flowchart models :
a. First of all, it must be determined how many days of prediction you want, the length of the day
prediction results, and the dependent variable or dependent variable whose value is affected
the dependent variable will be made from the closing price column minus the number of days
Then the prediction column will be subject to the shift function to increase data
so that there is blank data at the end of the data which will be filled in by the price
prediction.
c. The independent variable will be separated from the dependent variable and reduced by how much
new is x.
d. The dependent variable will be separated from the independent variable and reduced by how much
new namely y.
e. Then the x and y variables will be divided into training data and testing data.
Machine Translated by Google
38
f. The training process on the Linear Regression and Decission Tree Regression models.
h. The prediction process on the Linear Regression and Decission Tree Regression models.
3.3 Evaluation
The evaluation process will be carried out after the prediction process uses an algorithm model
the results have been obtained, and it is known how the visualization of the predicted results is
the. The evaluation carried out is to observe how the prediction results are produced
by the algorithm model using the error calculation matrix using the matrix
Mean Absolute Error (MAE), Mean Squared Error (MAE), Root Mean Squared Error
(RMSE), whether price predictions and trends that are formed can follow the actual price or
39
CHAPTER IV
4.1 Implementation
All stages of the research design have been described in the form of a flowchart
in Figure 3.1, implemented in program code using a programming language
Python 3.7. The process of the program code will be described in this chapter.
40
Figure 4.4 defines the function to carry out the Exploratory Data Analysis process
(EDA). Because the data used has been arranged neatly and well, the EDA process
not too much to do. With the EDA process, some insights were obtained that the amount
data row 1613 with 6 columns and date being the data index. Then the data type
visualized data is done to find out how the data is displayed on the line chart
41
2. print(nflx_tcn.shape) 3.
print(nflx_tcn.info())
4. print(nflx_tcn. isnull())
5.
8. plt. plot(nflx_tcn['Close'])
9. plt. title('NFLX Stock Closing Price', fontsize - 24)
10. plt. xlabel('Days')
11. plt.ylabel('Close Price $USD')
12. plt. show()
42
2. nflx_tcn = nflx_daily[['Close']]
3. nflx_tcn. head()
4.
5. # Scaling Data
6. scaler = Scaler()
43
Building Models
Figure 4.9 defines the functions for building a TCN model, several
make use of the TCNModel function. The length of the data to be trained is 1553 dan
with output length = 60. In this study the hyperparameter is set to: n_epoch =
The number of epochs used is 20 according to the research, then the dropout value
use 0.1 because it is the most commonly used value, use dilatation_base
the default value is 2 so that the known pattern is not too wide. And then with a big
2. tcn_model = TCNModel(
3. input_chunk_length = 1553,
4. output chunk_length = 60,
5. n_epoch = 20,
6. dropout = 0.1,
7. dilation_base = 2,
8. weight_norm = True,
9. kernel_size = 5,
10. num_filters = 3
11. random_state = 0
12. )
44
Training Process
Figure 4.10 defines the function to carry out the training process on data.
Backtesting Process
Figure 4.11 defines the function to evaluate the performance of the TCN model that has been
preformed in the 2nd line of code with the variable name backtest and with
make use of the historical_forecast function . Multiple hyperparameters are used in functions
In this case, forecast_horizon is how long the day will be predicted. With a span of 60 days
and no retraining.
Python from the flowchart figure 3.3 Long Short Term Memory (LSTM) algorithm.
Machine Translated by Google
45
46
Figure 4.15 defines the function to carry out the Exploratory Data Analysis process
(EDA). Because the data used has been arranged neatly and well, the EDA process
not too much to do. With the EDA process, some insights were obtained that the amount
data row 1613 with 6 columns and date being the data index. Then the data type
visualized data is done to find out how the data is displayed on the line chart
47
2. Print(nflx_df. shape)
3. Print(nflx_df.info())
4. Print(nflx_df. isnull())
5.
8. Plt.plot(nflx_df['Close'])
48
Figure 4.18 defines the function to retrieve the close column in the dataframe
nflx_df, only the close column will be used in this study. Then data
changed to be of type array and divided into training and testing data with
comparison of 80% and 20%, on the 8th line of code by setting the training data parameter
to 0.80.
2. df = nflx_df. filter(['Close'])
3.
6.
7. # Get the number of rows to train the model, 80% of the dataset
9. training_data_len
Scaling Function
Figure 4.19 defines the scaling function stored in the scaler variable, which
make use of the sklearn.preprocessing library. The data will then be scaled to depth
range from 0 to 1 in the 3rd line of code and apply the fit_transform function to
Machine Translated by Google
49
the dataset to be scaled on the 4th line of code. Figure 4.20 shows the data after
subjected to a scaling function .
4. scaled_data = scaler.fit_transform(dataset)
5. scaled_data
50
3. train_data = scaled_data[0:training_data_len, :]
4.
7. x_train = []
8. y_train = []
9.
11. # Then y_train for the pass through will contain 1 data indexed 60
51
7. features)
52
2. model = Sequential()
6. model. add(Dense(25))
7. model. add(Dense(1))
8.
5. x_test = []
6. y_test = dataset[training_data_len:, :]
53
Prediction Process
the LSTM model requires a 3-dimensional array of (number of samples, number of time
steps, number of features). The data that is owned is still 2-dimensional, so it must be done
reshaping then the data will be predicted. After the prediction results are obtained,
the inverse function is applied to reverse the price as before. The predicted results are shown
in Figure 4.27.
2. x_test = np.array(x_test)
3.
7. features)
54
Python from the flowchart figure 3.4 Linear Regression algorithm and Decision Tree Regression.
Linear Regression and Decision Tree Regression algorithms that have been provided by the library
Scikit-Learn (sklearn).
55
56
visualized data is done to find out how the data is displayed on the line chart
by using the close price column as shown in Figure 4.33.
2. print(nflx_daily. shape)
3. print(nflx_daily.info())
4. print(nflx_daily. isnull())
5.
8. plt. plot(nflx_daily['Close'])
57
Figure 4.34 defines the function to retrieve the close column in a dataframe
2. nflx_daily = nflx_daily[['Close']]
3. nflx_daily. head()
Figure 4.35 defines a new variable named future_days with a value of 60 which
is how long the day will be predicted later on the 2nd line of code. Then
there is a function to create a new column called Prediction whose values are taken from
the close column in the nflx_daily dataframe. The Prediction column's value is subject to the shift function
a number of values of the future_days variable, the results are shown in Figure 4.36.
Machine Translated by Google
58
2. future_days = 60
3.
5. nflx_daily['Prediction'] = nflx_daily[['Close']]
6. .shift(-future-days)
7. print(nflx_daily. head())
8. print(nflx_daily. tail())
Figure 4.35 Creating the future days variable and the prediction column
named X (independent) and y (dependent) are taken from the nflx_daily dataframe
3. x = np.array(nflx_daily.drop(['Prediction'], 1))[:-future_days]
4. y = np.array(nflx_daily['Prediction'])[:-future_days]
5.print(X)
6.print(y)
59
Figure 4.38 defines the function to split the dataset into training data and data
testing with a ratio of 75% to 25%, the data is subject to the random_state function so that
the data does not experience randomization and remains coherent which is defined in the 2nd line of code.
After the split is done, the dimensions of the data will be checked with the results (1164, 1) training data, (389,
1) testing data.
Figure 4.38 Dividing the dataset into training and testing data
Training Process
Figure 4.39 defines the functions to call both models that make use of
In the available parameters, just enter the data x_train and y_train, and process
3. lr = LinearRegression().fit(x_train, y_train)
4.
60
Figure 4.40 defines a function to create a new variable namely x_future which is
contains the value from the close column in the nflx_daily data frame which is only taken as much
4. X_future = np.array(x_future)
5. X_future
Prediction Process
Figure 4.41 defines the function to perform the prediction process on both models
make use of the library from sklearn.linar_model in the 2nd line of code and sklearn_tree in
6th line of code. In the available parameters, just enter the data x_test and y_test, and
model prediction process will be carried out. The results of the predictions of the two models are shown in
Figure 4.42, the top array is the predicted result of the Decision Tree Regression model
and the bottom one is the predicted result of the Linear Regression model.
2. lr_prediction = lr.predict(x_future)
3. print(lr_prediction)
4.
6. tree_prediction = tree.predict(x_future)
7. print(tree_prediction)
61
4.2 Visualization
The following is a visualization of the results of predictions that have been made previously
each algorithm.
62
2. valid['Prediction'] = backtest
3.
6. plt. plot(train['Close'])
The following is a visualization of the predictions made using the TCN algorithm
for 60 days. Figures 4.44 and 4.45 show the visualization results. Can be seen on
the visualization generated by the prediction results of the TCN model shows the trend that occurs
able to follow the current trend. The price difference between the actual price and the predicted price
quite small.
63
After making predictions with the model that has been built, then
visualize the results, to know the predicted price trend with the actual trend.
2. train = df[:training_data_len]
3. valid = df[training_data_len:]
4. valid['Predictions'] = lstm_predictions
5.
8. plt. plot(train['Close'])
64
The following is a visualization of the predictions made using the LSTM algorithm
for 60 days. Figures 4.47 and 4.48 show the visualization results. Can be seen on
the visualization generated by the prediction results of the LSTM model shows the trend that occurs
able to follow the current trend. The price difference between the actual price and the predicted price is not
too far.
After making predictions with the model that has been built, then
visualize the results, to know the predicted price trend with the actual trend.
Figure 4.49 and Figure 4.52 define functions for visualizing prediction results.
Machine Translated by Google
65
lr_predictions
4.
7. plt. plot(train['Close'])
The following is a visualization of the predictions made using the Linear algorithm
Linear Regression for 60 days. Figures 4.50 and 4.51 show the visualization results. Can
seen in the visualization produced by the predicted results of the Linear Regression model
shows the trend that occurs is not able to follow the actual trend. Price difference between
the actual price with the predicted price is too far. It can be categorized as
underfitting, because the model cannot capture patterns that occur properly so that results
predictions get low accuracy. The predicted trend is also the opposite
the actual trend, the predicted trend of price increases while the actual trend
66
67
2. valid = nflx_daily[X.shape[0]:]
3. Valid['Predictions'] = tree_predictions
4.
7. Plt. plot(train['Close'])
13.Fontsize = 24)
14. Plt.show()
Figure 4.52 Function to display the visualization of the Decision Tree Regression model
Figure 4.53 Visualization of the overall prediction of the Decision Tree Regression model
Machine Translated by Google
68
Figure 4.54 Visualization of the predictions of the Decision Tree Regression model in detail
The following is a visualization of the predictions made using the Decision algorithm
Tree Regression for 60 days. Figures 4.53 and 4.54 show the visualization results. Can
seen in the visualization produced by the prediction results of the Decision Tree Regression model
shows the trend that occurs is able to follow the actual trend. Price difference between prices
actual to the predicted price is very close, but at some point the predicted price
experienced a sharp spike. This can be categorized as overfitting, because of the model
too focused on training data so that if it predicts other data it will get accuracy
The low one. The predicted trend is too close to the actual trend.
4.3 Evaluation
After making predictions with the model that has been built and visualized
the result, the next step is to perform calculations using the error matrix that occurs
between the predicted results and the actual price. Figure 4.55 defines the function for
calculating matrices.
Machine Translated by Google
69
2. Print("TCN Metric")
8. mean_squared_error(val, backtest)))
9.
70
Based on the prediction results that have been obtained, and the existing error matrix values
in table 4.1, the implementation of the Temporal Convolutional Network (TCN) model has
RMSE 9,890 which is the lowest value. Then the performance of TCN can be followed
by an algorithm that is quite popular used in the Long Short Term Memory (LSTM)
which has a very small difference in the RMSE value of 10,843 with the RMSE TCN value.
As for the algorithm that is not devoted to processing time series data results
what I got was really bad. However, for the Linear Regression algorithm itself
get a fairly low RMSE value of 11,906, while the Decision Tree algorithm
Regression got the worst RMSE value, namely 36,679. The dilatation process
performed by the TCN algorithm can recognize data that is far in the past, so the model
can recognize patterns from data better and not depend on short-term data only.
Although the results obtained by TCN in this study were not too significant in comparison
with LSTM.
Meanwhile, if the performance of the algorithm model is seen from the visualization side, the predictions are
the resulting TCN and LSTM algorithms are able to provide trend predictions that can follow
the actual trend and have a price difference that is not too big. For Linear algorithms
Regression, the trend prediction results obtained are the opposite of the actual trend so that
it can be said that the model is experiencing underfitting because it cannot recognize patterns
well. Whereas in the Decision Tree Regression algorithm, the trend prediction results are
obtained is too similar to the actual trend or commonly called the prediction experienced
overfitting. The model is too fixated on the data used for the training process
71
CHAPTER V
CLOSING
5.1 Conclusion
predicting the trend of stock price movements and the Long Short Term Memory (LSTM) algorithm
b. The TCN algorithm can be built using the special Darts library
developed to process time series data and there is a TCN algorithm module,
then the hyperparameter tuning process is carried out according to the data
processed.
c. Both TCN and LSTM have a fairly small error value, that is, with a value
The TCN RMSE is 9,890 and the LSTM RMSE is 10,843. As for the algorithm
Linear Regression and Decision Tree Regression have a fairly large error value
namely 11,906 and 36,679, although the RMSE Linear Regression values can be said
close to the values of TCN and LSTM. RMSE value. So that algorithm is not
d. The visualizations produced by the TCN and LSTM algorithms are able to follow trends
predict the trend of stock price movements on the stock exchange, but not necessarily
about the world of stock investment well and ready to accept the risks that will
borne.
5.2 Suggestions
After the conclusions obtained from the research conducted, this research is still valid
there are many shortcomings that must be corrected in the future to be able to produce results
which is more optimal and useful. Here are suggestions that can be considered for
72
a. The stock data used is not just one issuer, it is expected that the algorithm model
can be applied to various stock issuers or stocks in an index and
certain stock sector.
73
BIBLIOGRAPHY
Agusta Nanda, R., Rizal, S., & Yuswaliani, S. (2016). Fundamental Analysis and Analysis
technical. https://www.academia.edu/32854302/Analisis_fundamental
Ahmar, US (2018). Sutte indicator: An Approach to Predict the Direction of the Stock Market
https://doi.org/10.14456/sjst-psu.2018.150
axa.co.id. (2019). The Beginning of the History of the Netflix Streaming Platform You Need to Know!
https://portal.axa.co.id/direct/Tips/Detail/awal-mula-history-netflix-yang-perlu-kamu
know
Bai, S., Kolter, JZ, & Koltun, V. (2018). An Empirical Evaluation of Generic Convolutional
https://www.cnbcindonesia.com/market/20210629153854-17-256818/naik-56-quantum
investors-capital-market-ri-reach-388-million
Coded. (2020). What Is Artificial Intelligence? The following definition and examples.
https://www.dicoding.com/blog/artificial-intelligence-is/
Filbert, R. (2020a). Swing Trader World Stock Investment (H. Yulianto, Ed.; Print
Filbert, R. (2020b). Investment in Stocks A la Swing Trader World (H. Yulianto, Ed.; 14th ed.). Elex
Media Komputindo.
Hafizah, N., Noviani, E., & Perdana ABSTRACT, H. (2019). Lq-45 Stock Technical Analysis
Using the Bollinger Bands Indicator. Math Scientific Bulletin. Stats. and Applied
Ika Ramadhani, P. (2020, July 2). S&P 500 and Nasdaq Strengthen Driven by Developments
nasdaq-strengthening-coronavirus-vaccine-positive-development-driven
invest.kontan.co.id. (2021, March). Until March 2021, the IDX records an increase in numbers
increase-number-of-investors-by-27
Jati Lantang M, N. (2020). Comparison Between SVM and CNN To Detect Objects
74
Karno, ASB (2020). Prediction of BRI Bank Stock Time Series Data with Learning Machines
LSTM (Long Short Term Memory). Journal of Informatics and Information Security, 1(1).
https://doi.org/10.31599/jiforty.v1i1.133
Kim, T., & Kim, HY (2019). Forecasting stock prices with a LSTM-CNN fusion feature
model using different representations of the same data. PLoS ONE, 14(2).
https://doi.org/10.1371/journal.pone.0212320
Kusumodestoni, RH, & Sarwido, S. (2017). Comparison of Model Support Vector Machines
(SVM) and Neural Networks to Determine the Accuracy of the Highest Price Prediction
https://medium.com/unit8-machine-learning-publication/temporal-convolutional
networks-and-forecasting-5ce1b6e97ce4
Lestari, WR, & Pranyoto, DE (2015). Psychological Factors that Shape Behavior
Investor Shares in the Capital Market Transactions in Lampung. Winda Rika Lestari and
Liu, Y., Dong, H., Xingmei, W., & Han, S. (2019). Time Series Prediction Based on Temporal
Mehtab, S., Sen, J., & Dutta, A. (nd). Stock Price Prediction Using Machine Learning and
Infrastructure and Logistics Planning View project Sidra Mehtab NSHM Knowledge
Campus Stock Price Prediction Using Machine Learning and LSTM-Based Deep
money.kompas.com. (2021). Number of Subscribers Surges in the Midst of a Pandemic, Netflix Earns
https://money.kompas.com/read/2021/01/20/165327826/nomor-pelanggan-melonjak-di
mid-pandemic-netflix-earned-revenue-rp-350
75
https://dspace.uii.ac.id/bitstream/handle/123456789/7843/TUGAS%20AKHIR_TRIAN
O%20NURHIKMAT_14611209_STATISTICS_UII.pdf?sequence=1&isAllowed=y
https://colah.github.io/posts/2015-08-Understanding-LSTMs/
Pham, DT, & Pham, PTN (1999). Artificial Intelligence in Engineering. International
6955(98)00076-5
Pramudya, R., & Pramudya, R. (2020). Technical Analysis to Determine Buying and Selling
Signals in Stock Trade. International Journal of Finance & Banking Studies (2147-4486),
R Tristia, R. (2019, October 30). Trading Psychology and Emotional Control for Traders.
https://id.catinstitute.org/market-story/read/psikologi-trading
Rich, E., Knight, K., & B Nair, S. (2019). Artificial Intelligence (3rd ed.). The McGrow Hill.
Roziq, M. (2021). Know What is AI (Artificial Intelligence)? The following types, forms and
following-type-form-and-application-in-life/
Now. (2020, July 31). Get to Know the Types of Stock Charts for Profit.
https://ajaib.co.id/mengenal-tipe-tipe-chart-saham/
https://id.tradingview.com/chart/?symbol=FX_IDC:USDIDR&source=unauth_header&f
eate=launch_chart
Tri Retno, I. (2021, March 4). Get to know about Sideways or Consolidation Trends.
https://www.finansialku.com/sideways/
Wan, R., Mei, S., Wang, J., Liu, M., & Yang, F. (2019). Multivariate Temporal Convolutional
Network: A Deep Neural Networks Approach for Multivariate Time Series Forecasting.
Wang, X., Wang, Y., Weng, B., & Vinel, A. (2020). Stock2Vec: A Hybrid Deep Learning
Framework for Stock Market Prediction with Representation Learning and Temporal
Wayan, D. (2018, February 6). Understanding Artificial Intelligence in the form of Deep Learning and
76
Zayini Anwar, M., & Habibi, S. (nd). Analysis of Prediction of Stock Movement Direction Performance
Apple (APPL) uses the Recurrent Neural Networks/ Long Short Term Memory Method
Networks (RNN/LSTM).
Machine Translated by Google
ATTACHMENT