## 6 Concluding Discussion  
This paper offers a small experiment to assess the potential of deep learning algorithms to predict markets. Using data on all stocks on the S&P 500 index from 1963 to 2016, we train a fully connected, feed-forward deep learning network with three hidden layers of 200 nodes each to predict the direction of the S&P 500 index daily. Unlike existing tests of weak-form market efficiency, which use a single return series to test for autocorrelation, this new approach expands the information set by a huge order of magnitude, i.e., by using return data from all stocks in the index for the past 30 days. The trained prediction model is then used for look-ahead periods ranging from 10 to 30 days, and more.  
Over the entire sample period, the percentage of days for which the S&P index moves up is 52.7%. Therefore, our prediction algorithm needs to predict up moves better than this percentage and not just do better than 50%. (Note that a naive algorithm that predicts markets always move up will be correct 52.7% of the time.) With look-ahead periods of 10 days (OS), we find that the model gets the predicted movement correct about 58% of the time. For a look-ahead period of 30 days the accuracy is 55%. While this is greater than 52.7%, it is not statistically strong enough to claim that deep learning is able to predict the markets. We may therefore conclude that our tests, which use vastly greater information sets than hitherto used in weak-form tests of market efficiency, do not uncover strong evidence of market inefficiency. However, the shapes of the histograms in Figures 9-11 suggest that the model is performing well as more of the density loads to the right of the average up-move percentage line. This visual depiction is also reflected in the FPAA metric shown in Table 1. We conjecture that more tuning of the architecture may lead to better predictability, though of course this requires further examination. We close by recommending further exploration into neural net architectures better tailored and tuned for this specific prediction problem.  
Conceptualization, S.D.; Data curation, K.M.; Formal analysis, S.D., K.M. and R.C.; Investigation, K.M.; Methodology, S.D. and K.M.; Software, K.M. and R.C.; Supervision, S.D.; Validation, K.M.; Visualization, K.M.; Writing - original draft, S.D. and K.M.; Writing - review & editing, S.D.  
This research received no external funding.  
We are very grateful to three anonymous referees for their excellent inputs that helped improve the paper immensely. We thank participants for their comments in seminars at the Stockholm School of Economics, TwoSigma, Fordham University, the Bay Area R User Group, Research Affiliates, and CFA San Francisco.  
The authors declare no conflict of interest.  
\begin{table}
\begin{tabular}{l c c} \hline \hline
**Prediction Model** & **OA** & **FPAA** \\ \hline Deep Learning & 0.582 (0.36) & 0.589 \\ Logistic Regression & 0.517 (0.06) & 0.667 \\ Decision Tree & 0.502 (0.15) & 0.633 \\ Random Forest & 0.491 (0.24) & 0.598 \\ Linear Discriminant Analysis & 0.509 (0.11) & 0.658 \\ k Nearest Neighbors & 0.511 (0.10) & 0.645 \\ Naive Bayes & 0.497 (0.19) & 0.618 \\ Support Vector Machine & 0.517 (0.07) & 0.678 \\ \hline \hline \end{tabular}
\end{table}
Table 3: Prediction accuracy for various machine learning models. We report the overall accuracy (OA) and FPAA. The training sample is of size \(N=5000\), with a lookback period of \(L=30\) days and forecast period of \(F=10\) days. We also report how far from the threshold of 0.527 (in standard deviations) the OA is, shown in parenthesis next to the OA value. In no case, is the predictive power significant.