Metadata-Version: 2.1
Name: quantglobal
Version: 0.0.3
Summary: This package allows access to data provided by Quantitative Global.
Author: Quantitative Global Indices, LLC (Earl Charles)
Author-email: <echarles@qg-indices.com>
License: UNKNOWN
Keywords: python,quantitative finance,alternative data,statistics,stocks
Platform: UNKNOWN
Classifier: Programming Language :: Python :: 3
Classifier: Operating System :: OS Independent
Description-Content-Type: text/markdown
Requires-Dist: pandas
Requires-Dist: requests

# Quantitative Global - v1 API

This package allows access to data provided by [Quantitative Global Indices](https://qg-indices.com/).

## Installation

Use the package manager [pip](https://pip.pypa.io/en/stable/) to install quantglobal.

```bash
pip install quantglobal
```

## Usage

```python
import QuantGlobal as qg
data = qg.download(key, strategy, underlying, from_date, **end_date)
```
### Valid parameters
- key
  - the email address associated with your account (e.g., 'your_address@ email.com')
- strategy
  - 'dca' (Dual Class Arbitrage)
  - 'pt' (Pairs Trading)
  - 'pt_extended' (Pairs Trading w/ Extended Data)
- underlying
  - For Dual Class Arbitrage ('dca'), the valid underlying parameters are:
    - 'google','zillow','fox','news'
  - For Pairs Trading (both 'pt' and 'pt_extended'), the valid underlying parameters are:
    - 'communications','consumer_discretionary','consumer_staples','energy','financials','healthcare','industrials','basic_materials','technology','utilities'
- from_date / end_date (optional)
  - date in YYYY-mm-dd format
  
## Sample Request

```python
import QuantGlobal as qg
data = qg.download(key = 'authenticated_user@email.com', strategy = 'dca', underlying = 'google', from_date = '2022-11-25')
```
Output:
| datetime             | GOOG Cumulative Returns | GOOGL Cumulative Returns | Spread | GOOG Intraday Performance | GOOGL Intraday Performance |
|----------------------|-------------------------|--------------------------|--------|---------------------------|----------------------------|
| 2022-11-25 09:30:00  | 100                     | 100                      | 0      | 0.00%                     | 0.00%                      |
| 2022-11-25 09:31:00  | 100.08                  | 100.13                   | 0.05   | 0.08%                     | 0.13%                      |
| 2022-11-25 09:32:00  | 100.24                  | 100.27                   | 0.03   | 0.24%                     | 0.27%                      |


