Binance Live Returns Crypto Trading Dashboard with Python and Streamlit

Algovibes
30 Jan 202223:02

Summary

TLDRIn this tutorial, viewers learn to create a real-time dashboard for tracking the top and worst performers on the Binance trading platform. The video guides through setting up live price streams using the Unicorn Binance WebSocket API, importing data into an SQL database, and calculating returns over various look-back periods. It culminates in building an interactive user interface with Streamlit, allowing users to easily view and update performance data. This comprehensive approach empowers viewers to gain insights into cryptocurrency trends while enhancing their programming skills.

Takeaways

  • 😀 The video demonstrates how to build a real-time dashboard to track the top and worst performers on the Binance platform.
  • 📈 It uses a one-minute lookback period to analyze performance, allowing for quick updates and insights.
  • 🔄 Viewers can change the lookback period (e.g., to 15 minutes) to see different performance metrics.
  • 📦 The Unicorn Binance WebSocket API is introduced as a tool for accessing live price streams for cryptocurrencies.
  • 🔍 The video guides viewers through the process of setting up the necessary libraries and creating a price stream for Bitcoin, BNB, and ETH.
  • 💾 A SQL database is used to store live prices, allowing for easy retrieval and calculation of returns.
  • 📝 The script includes functions for calculating cumulative returns based on historical price data stored in the database.
  • 📊 Users can retrieve and display top and worst performers based on the calculated returns for all available coins.
  • 🎛️ Streamlit is utilized to create a user-friendly dashboard interface, allowing for real-time updates and visualizations.
  • 💻 The final product is a live return screener that displays performance metrics and allows user interaction through an update button.

Q & A

  • What is the main purpose of the dashboard mentioned in the video?

    -The main purpose of the dashboard is to provide real-time data on the top and worst performers on the Binance platform, allowing users to analyze performance over different lookback periods.

  • Which library is used to obtain a live stream of prices from Binance?

    -The video uses the Unicorn Binance Websocket API library to obtain a live stream of prices for all available coins on the Binance platform.

  • What are the two main streams defined for tracking prices?

    -The two main streams defined for tracking prices are the trade stream and the candlestick one-minute stream.

  • How does the dashboard allow users to customize their data view?

    -Users can customize their data view by clicking the update button to get real-time results and by changing the lookback period in minutes, such as 1 or 15 minutes.

  • What SQL database technology is used to store the live price data?

    -The video demonstrates the use of SQLite to store live price data for the coins on Binance.

  • What does the 'sql_import' function accomplish?

    -The 'sql_import' function takes live price data from the stream and writes it into the SQL database, organizing the data by symbol, event time, and closing price.

  • What method is used to calculate the cumulative return for the cryptocurrencies?

    -The cumulative return is calculated using the relative change of the price column over the specified lookback period, taking the product of the relative changes after adding one.

  • How does the script handle missing or non-K-line data?

    -The script checks for the presence of data and ensures that the data received is a K-line stream by verifying the length of the data before proceeding with further processing.

  • What is the function of Streamlit in the final part of the script?

    -Streamlit is used to create a web dashboard that displays the live return screener, allowing users to interactively view top and worst performers along with performance updates based on their selected lookback periods.

  • What enhancements can be added to the dashboard as suggested in the video?

    -The video suggests that viewers can propose additional features or enhancements for the dashboard in the comments, hinting at the possibility of expanding the dashboard's functionality based on user feedback.

Outlines

plate

هذا القسم متوفر فقط للمشتركين. يرجى الترقية للوصول إلى هذه الميزة.

قم بالترقية الآن

Mindmap

plate

هذا القسم متوفر فقط للمشتركين. يرجى الترقية للوصول إلى هذه الميزة.

قم بالترقية الآن

Keywords

plate

هذا القسم متوفر فقط للمشتركين. يرجى الترقية للوصول إلى هذه الميزة.

قم بالترقية الآن

Highlights

plate

هذا القسم متوفر فقط للمشتركين. يرجى الترقية للوصول إلى هذه الميزة.

قم بالترقية الآن

Transcripts

plate

هذا القسم متوفر فقط للمشتركين. يرجى الترقية للوصول إلى هذه الميزة.

قم بالترقية الآن
Rate This

5.0 / 5 (0 votes)

الوسوم ذات الصلة
Binance DashboardLive DataCrypto TradingReal-Time AnalysisPython ScriptUnicorn APISQL DatabaseData StreamCrypto PerformanceFinancial Dashboard
هل تحتاج إلى تلخيص باللغة الإنجليزية؟