An open API service indexing awesome lists of open source software.

https://github.com/RajdeepKonwar/stockast

Predict stock market pricing over 180 minutes using Black-Scholes stochastic modeling and parallel Monte-Carlo simulations.
https://github.com/RajdeepKonwar/stockast

black-scholes c-plus-plus monte-carlo-simulation openmp parallel prediction-model predictive-analytics predictive-modeling stock-data stock-market stock-prediction stock-price-prediction stock-prices thread

Last synced: 6 months ago
JSON representation

Predict stock market pricing over 180 minutes using Black-Scholes stochastic modeling and parallel Monte-Carlo simulations.

Awesome Lists containing this project

README

          

# Stockast [![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2FRajdeepKonwar%2Fstockast.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2FRajdeepKonwar%2Fstockast?ref=badge_shield)
## Stock Market Forecasting using Parallel (OpenMP) Monte-Carlo Simulations

![alt text](https://i.imgur.com/dHf0aRO.png)

### Compile Instructions
#### Windows
* Open `stockast.sln`
* [Optional] Right-click Solution 'stockast' in the Solution Explorer and select `Retarget solution`
* Build and run!

#### Linux
```
make
```
Type `make clean` to clean object file and executable.

### Run Instructions
#### Windows
Simply run from Visual Studio or double-click the executable created inside x64\\{config}\stockast.exe

By default, the program will try and utilize the maximum system threads available. In order to use a specific number of threads, set the environment vairable `OMP_NUM_THREADS` equal to the number of threads you want.

#### Linux
Set the number of threads to be used for computation,
```
export OMP_NUM_THREADS=number_of_threads
```
For example, `export OMP_NUM_THREADS=8`.
Then run the program
```
./stockast
```

![image](https://user-images.githubusercontent.com/22571164/212611578-cec8eecf-a858-467d-967b-79315ea33d60.png)

### General info
* The input file "data.csv" contains the stock-price values for 3 hours prior to run-time; this acts as the history-data and helps estimate the market volatility.
* The output file "opt.csv" contains the output (most likely outcome) price-vector from our code. One can use Excel or gnuplot to plot the resulting line graph of the predicted stock pricing.
* (**Linux only**) The script "profiling.sh" runs the parallel code from 1 to the specified number of threads. To use the script,
```
./profiling.sh "number_of_threads"
```
For example, `./profiling.sh 8`.