A simple web application to track the prices and historical data of popular cryptocurrencies using the Gemini API and CryptoCompare API. Built with Python, Streamlit, Pandas, Matplotlib, and Plotly.
- Display current price, bid price, and ask price for selected cryptocurrencies.
- Display historical data with customizable time frames.
- Interactive candlestick chart for visualizing historical price data.
- Real-time data refresh.
- Python
- Streamlit
- Requests
- Pandas
- Matplotlib
- Plotly
- Dotenv
- Python 3.6 or higher
- Pip (Python package installer)
-
Clone the repository:
git clone https://github.com/yourusername/crypto-price-tracker.git cd crypto-price-tracker
-
Create and activate a virtual environment:
python -m venv venv source venv/bin/activate # On Windows, use `venv\Scripts\activate`
-
Install the required packages:
pip install -r requirements.txt
-
Set up your environment variables:
- Create a
.env
file in the project directory. - Add your CryptoCompare API key to the
.env
file:CRYPTOCOMPARE_API_KEY=your_cryptocompare_api_key
- Create a
-
Run the Streamlit app:
streamlit run app.py
-
Open your browser and navigate to the URL provided by Streamlit (usually
http://localhost:8501
).
- Select the cryptocurrency you want to track from the sidebar (BTC, ETH, LTC, BCH, ZEC).
- Select the time frame for historical data (1m, 5m, 15m, 30m, 1h, 6h, 1d).
- View the current price, bid price, and ask price in the main window.
- View the historical data table and the candlestick chart for the selected cryptocurrency and time frame.
- Fork the repository.
- Create a new branch (
git checkout -b feature/your-feature-name
). - Commit your changes (
git commit -m 'Add some feature'
). - Push to the branch (
git push origin feature/your-feature-name
). - Create a new Pull Request.