Skip to main content

Library combining the power of CCXT with Pandas.

Project description

Crypto-Pandas

Python version GitHub PyPI version Downloads Binder Explore Data License Code style: black Docs Medium badge

CCXT DATA → PANDAS DATAFRAME IN JUST 1 LINE OF CODE

Crypto-Pandas fuses the power of Pandas with the market-connectivity of CCXT. It turns CCXT’s nested JSON into clean, typed DataFrames for analysis, backtests, or real-time dashboards — and lets you place/cancel live orders using the same DataFrame-centric API.

Why Crypto-Pandas?

1-liners, everywhere. Fetch OHLCV, tickers, trades, order books, balances, orders → all as DataFrames.

  • Consistent columns & dtypes. Timestamps as UTC datetime64[ns, UTC], numeric columns as proper numerics.
  • Zero boilerplate. Stop writing JSON-to-DataFrame glue for every exchange.
  • CCXT-compatible. Keep your favorite CCXT params; just get DataFrames back.

Installation

Crypto-Pandas can be installed on Python 3.11~3.14:

pip install crypto-pandas

Examples

Find all examples in the Crypto-Pandas-Example Repository

Getting Started

Crypto-Pandas works near identically to CCXT. Just add exchange = CCXTPandasExchange(exchange=exchange) and the exchange methods provided by CCXT will be exposed to Crypto-Pandas. More examples can be found on Binder:

import ccxt
from crypto_pandas import CCXTPandasExchange

# Initialize a CCXTPandasExchange object
exchange = ccxt.binance(dict(apiKey="your_api_key_here", secret="your_secret_here"))
exchange = CCXTPandasExchange(exchange=exchange)

# OHLCV
ohlcv = exchange.fetch_ohlcv("BTC/USDT", timeframe="1m", limit=100)      # -> DataFrame
# Trades
trades = exchange.fetch_trades("BTC/USDT", limit=1000)                   # -> DataFrame
# Orderbook
ob = exchange.fetch_order_book("BTC/USDT", limit=50)                 # -> DataFrame
# Tickers
tick = exchange.fetch_tickers()                               # -> DataFrame

# Fetch open orders from an exchange
open_orders = exchange.fetch_open_orders(symbol="BTC/USDT")

# Halve the amount and edit orders
open_orders["amount"] /= 2
response = exchange.edit_orders(open_orders)

# Display the transformed orders dataframe
print(response)

Documentation

For detailed documentation, visit the ReadTheDocs or read the API reference for advanced features.

About Sigma Quantiphi

Sigma Quantiphi is a quantitative-engineering firm that builds end-to-end algorithmic-trading systems for the cryptocurrency markets. We create open-source, Python-first tools—like crypto-pandas—and deliver turnkey execution, data, and research pipelines that emphasize simplicity, transparency, and rapid deployment.

License

This project is licensed under the Apache License. See the LICENSE file for more details.

Contributing

Contributions are welcome! If you'd like to contribute, please fork the repository, create a new branch for your feature or fix, and send a pull request.

  1. Fork the repository.
  2. Create your feature/fix branch: git checkout -b my-new-feature.
  3. Commit your changes: git commit -am 'Add some feature'.
  4. Push to the branch: git push origin my-new-feature.
  5. Submit a pull request.

Support

If you encounter any issues or have questions, feel free to open an issue on the GitHub repository or contact us via email at contact@sqphi.com. Happy trading! 🚀

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

crypto_pandas-0.12.6.tar.gz (21.4 kB view details)

Uploaded Source

Built Distribution

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

crypto_pandas-0.12.6-py3-none-any.whl (28.2 kB view details)

Uploaded Python 3

File details

Details for the file crypto_pandas-0.12.6.tar.gz.

File metadata

  • Download URL: crypto_pandas-0.12.6.tar.gz
  • Upload date:
  • Size: 21.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.12.9 Windows/11

File hashes

Hashes for crypto_pandas-0.12.6.tar.gz
Algorithm Hash digest
SHA256 07f12618f22e603ecb8e8c43a1e37fc74d721bc924b1d3ec541d02a34d8044e7
MD5 8a8a7e7384520cc9f3f9876cfa8eb4a8
BLAKE2b-256 2d8b2b427f61e4a83283368359c0b16534503ca3b413c078a30eae6e6c3f54d3

See more details on using hashes here.

File details

Details for the file crypto_pandas-0.12.6-py3-none-any.whl.

File metadata

  • Download URL: crypto_pandas-0.12.6-py3-none-any.whl
  • Upload date:
  • Size: 28.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.2.1 CPython/3.12.9 Windows/11

File hashes

Hashes for crypto_pandas-0.12.6-py3-none-any.whl
Algorithm Hash digest
SHA256 87c67a6441175c93cdea10a488c15f372df47799982c0143fd7a10468f9acf6e
MD5 7d82ecab8deeb056497e663afa48c229
BLAKE2b-256 9c84094c3080573d91881951f70ffc9b5c543e434cb18163bc05c6f19c2adad9

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