Skip to main content

Financial data access and analysis library with market data, options calculations, and database integration

Project description

Sharpe - Financial Data & Analysis Library

A Python library for financial data access, market analysis, and options calculations.

Wrappers around Polygon and Financial Modeling Prep.

Features

  • Market Data: Stock prices, options data, and historical information
  • Alternative Data: News, earnings, and company profiles
  • Options Calculations: Black-Scholes pricing and Greeks
  • Database Integration: PostgreSQL with async support
  • AWS Integration: Cloud data retrieval

Installation

# From source
git clone https://github.com/wang-sanity/sharpe.git
cd sharpe
pip install -e .

# Using conda
conda env create -f environment.yml
conda activate tensorfi-sharpe

Quick Start

from sharpe.data import mkt
from sharpe.utils import options, time

# Get stock data
stock_data = mkt.get_stock_price("AAPL")

# Calculate option price
option_price = options.black_scholes(100, 105, 0.25, 0.05, 0.2)

# Market calendar
trading_day = time.closest_trading_day_now()

Package Structure

  • sharpe/data/ - Market and alternative data access, database operations
  • sharpe/utils/ - Options calculations, time utilities, universe management

Requirements

  • Python 3.11+
  • Core: pandas, numpy, scipy, sqlalchemy
  • Optional: PostgreSQL, AWS credentials

Development

# Setup
conda env create -f environment.yml
conda activate tensorfi-sharpe
pip install -e .[dev]

# Test
pytest

License

CC BY-NC 4.0 License - see LICENSE file for details.


Disclaimer: For educational and research purposes only. Consult qualified professionals before making investment decisions.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tensorfi_sharpe-0.1.0.tar.gz (45.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tensorfi_sharpe-0.1.0-py3-none-any.whl (38.9 kB view details)

Uploaded Python 3

File details

Details for the file tensorfi_sharpe-0.1.0.tar.gz.

File metadata

  • Download URL: tensorfi_sharpe-0.1.0.tar.gz
  • Upload date:
  • Size: 45.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.13

File hashes

Hashes for tensorfi_sharpe-0.1.0.tar.gz
Algorithm Hash digest
SHA256 53c2fb8bd2b6b236f40dd0e847c7816c048643bc12c56366a700714999ca92b6
MD5 3e2a63fd892314f005afe500b45a4a44
BLAKE2b-256 43e004e80793b1a25f0af0ee42b0bab41241f50c2adf23cee6ff072bfff20b31

See more details on using hashes here.

File details

Details for the file tensorfi_sharpe-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for tensorfi_sharpe-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 784179e40e0928e33be2e247b58dda62c9aa69c2cadf1845b5e18ded2dc11344
MD5 999921d8293b5a16afef8c680ea4c13d
BLAKE2b-256 0fd67960f6e359212c57f8079593c52e03dd230ef0c8999512b1906b0ca89d8c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page