PredictIt Tracking and Analysis
primary language: Python 2.7
requires Unix/Linux for Cron scheduling
Current:
-Polls the predictit.org API every minute to retrieve current pricing data as a JSON object
-Inserts data into SQLite3 database using SQLAlchemy ORM
-Processes requests for historical prices and outputs data as .csv
Future:
-Train LSTM neural network to predict price movement
Clone the directory:
git clone https://github.com/Talophex/PITA.git
Install pip.
Install dependencies:
pip install -r requirements.txt
Create the SQLite3 database to store data:
python CreateDatabase.py
Add cron job to poll API once per minute:
python CronScheduler.py
I. To dump price data into csv, run:
python DumpCSV.py <market-predictit-id>
A separate csv file will be created for each contract found in the specified market.
II. To disconnect the current database for storage, run:
python DisconnectDatabase.py
A new database will automatically be created by CreateDatabase.py to ensure no disruptions to data acquisition.