Created on 3rd November 2023
•
It can be used to predict future stock prices, analyze daily log returns, and optimize a portfolio so that the investor can divide the investment into various portions to be invested among various assets so as to output maximum profit. It can also be used to observe how two or more stocks relate with each other helping the investor to maximise the diversity meanwhile lowering the risks. It also takes into account risk factor which may be treated as a hyperparameter, allowing different optimal portfolios in different scenarios.
The usage of dataReader() created a problem along with some stock data which I solved using yf.download, it happened as the former didn't support some data formats. Also, the usage of moving average was incorporated to smoothen the plot of log daily returns, thus converting the histogram (which is a discrete distribution) into a continuous distribution. I used arithmetic Brownian motion over usual randomisation for generating the various random paths fed into the Monte Carlo Simulation.