You are on page 1of 22

University Institute of Engineering and

Technology
Panjab University, Chandigarh

Department of Electrical and Electronics Engineering

PROJECT WORK
CRYPTO-CURRENCY LIVE PRICE CHECKER

Submitted by :-Harsh Kumar UE204034


Himanshu Raj UE204037
Ivin Suresh UE204038
TABLE OF CONTENTS
1. Introduction
2. Software Required
2.1 Jupyter
2.2 Python
2.3 Tkinter
3. Crypto-currency
4. How Does Crypto-currency Work
5. Companies Supporting Cryptocurrencies
6. Different Sectors of Cryptocurrencies
7. Crypto Trading
7.1 Crypto Price Charts
7.2 Candlesticks in Crypto
8.How This Live Price Tracker Helps in Trading
9.Why Should One Invest in Crypto?
10. Source Code
11. Result/Testing
INTRODUCTION
A crypto currency price tracker monitors the current value of different
digital currencies and tokens. Many of these services provide historical
data as well, allowing users to compare current prices against older
values.

Cryptocurrency price trackers should use reliable data and consistently update
their data.
CoinMarketCap is the industry's most popular and recognizable cryptocurrency
price tracker; other trackers include Coinlib and Bitgur.
Software Required

• Jupyter ,Binance

• Front _design: tkinter

• Front end Language : Python


2.1 What is jupyter ?
Jupyter Notebook allows users to compile all aspects of a data
project in one place making it easier to show the entire process
of a project to your intended audience. Through the web-based,
users can create data visualizations and other components of a
project to share with others via the platform

One of the best parts of using Jupyter Notebook is its flexibility


and versatility, as you can work with the technology by
downloading Jupyter lab, or simply opening your browser to
use the notebook on the go through the original application. A
tool that was made for collaboration and interactivity, Jupyter
Notebook is also compatible with the most commonly used
programming languages such as R, C++, Ruby, and Python.
2.2 What is Python?
Python is an interpreted, object-oriented, high-level
programming language with dynamic semantics. Its high-
level built in data structures, combined with dynamic typing
and dynamic binding, make it very attractive for Rapid
Application Development, as well as for use as a scripting or
glue language to connect existing components together.
Python's simple, easy to learn syntax emphasizes readability
and therefore reduces the cost of program maintenance.
Python supports modules and packages, which encourages
program modularity and code reuse. The Python interpreter
and the extensive standard library are available in source or
binary form without charge for all major platforms, and can
be freely distributed
2.3 What is Tkinter ?
 Tkinter is the de facto way in Python to create Graphical User interfaces (GUIs) and is included in all
standard Python Distributions. In fact, it’s the only framework built into the Python standard library. 

This Python framework provides an interface to the Tk toolkit and works as a thin object-oriented
layer on top of Tk. The Tk toolkit is a cross-platform collection of  ‘graphical control elements’, aka
widgets, for building application interfaces.

This framework provides Python users with a simple way to create GUI elements using the widgets
found in the Tk toolkit. Tk widgets can be used to construct buttons, menus, data fields, etc. in a
Python application. Once created, these graphical elements can be associated with or interact with
features, functionality, methods, data or even other widgets. 
3. What is crypto currency ?
Cryptocurrency is a digital payment system that doesn't rely on banks
to verify transactions. It’s peer to peer system that can enable anyone
anywhere to send and receive payments. Instead of being physical
money carried around and exchanged in the real world, cryptocurrency
payments exist purely as digital entries to an online database
describing specific transactions. When you transfer cryptocurrency
funds, the transactions are recorded in a public ledger. Cryptocurrency
is stored in digital wallets.
Cryptocurrency received its name because it uses encrypted to verify
transactions. This means advanced coding is involved in storing and
transmitting cryptocurrency data between wallets and to public ledgers.
The aim of encryption is to provide security and safety.
The first cryptocurrency was Bitcoin, which was founded in 2009 and
remains the best known today. Much of the interest in cryptocurrencies
is to trade for profit, with speculators at times driving prices skyward.
4.How does cryptocurrency work?
• Cryptocurrencies run on a distributed public ledger called blockchain, a
record of all transactions updated and held by currency holders.
• Units of cryptocurrency are created through a process called mining, which
involves using computer power to solve complicated mathematical problems
that generate coins. Users can also buy the currencies from brokers, then
store and spend them using cryptographic wallets.
• If you own cryptocurrency, you don’t own anything tangible. What you own is
a key that allows you to move a record or a unit of measure from one person
to another without a trusted third party.
• Although Bitcoin has been around since 2009, cryptocurrencies and
applications of blockchain technology are
• Still emerging in financial terms, and more uses are expected in the future.
Transactions including bonds, stocks, and other financial assets could
eventually be traded using the technology.
5.Companies supporting
cryptocurrencies
6.Different Sectors of Cryptocurrencies

• Decentralized Exchange
This consists of exchanges that are like centralized exchanges but without the need of “signing up”
to the platform. Decentralized exchanges (DEX) are a type of cryptocurrency exchange that allows
for direct peer-to-peer cryptocurrency transactions to take place online securely and without the
need for an intermediary. The top 3 in this sector are:
Uniswap (UNISWAP)
Stellar Lumens (XLM)
Pancake Swap (CAKE)

• DeFi (Decentralized Finance)


Decentralized finance is a system by which financial products become available on a public
decentralized blockchain network, making them open to anyone to use, rather than going through
middlemen like banks or brokerages. The top 3 in this sector are:
Uniswap (UNI)
Chainlink (LINK)
Aave (AAVE)
• NFT (Non-Fungible Token)
A non-fungible token (NFT) is a unit of data stored on a digital
ledger, called a blockchain, that certifies a digital asset to be
unique and therefore not interchangeable. The top 3 in this space
are:
Theta (THETA)
Chiliz (CHZ)
Decentraland (MANA)

• Metaverse
The Metaverse (always capitalized in Stephenson's fiction)
is described as a shared "imaginary realm" that is "made
available to the public across the worldwide fiber-optics
network" and projected onto virtual reality goggles in the
novel. Therefore, the phrase can apply to digital settings
that have been enhanced with virtual reality (VR) or
augmented reality (AR). 
Meta in the term means “beyond” and verse refers to the
“universe.”
7.What is crypto trading?
• Cryptocurrency trading means taking a financial position on the price
direction of individual cryptocurrency against the dollar (in crypto/dollar
pairs) or against another crypto, via crypto to crypto pairs. CFDs (contracts
for difference) are a particularly popular way to trade cryptocurrencies as
they allow for greater flexibility, the use of leverage and the ability to take
short as well as long positions
• There has been a surge of interest in cryptocurrencies over the past few
years. That demand has led to many CFD trading platforms and brokers
now offering cryptocurrency trading pairs. These trading pairs can include
one cryptocurrency, for example, Bitcoin, and one fiat currency, such as the
US dollar. Here the trader makes a profit, or loss, by forecasting whether
the cryptocurrency side of the pair will gain or lose value against the fiat
currency.
• The other kind of cryptocurrency pair is made up of two different
cryptocurrencies, for example, Bitcoin and Ethereum. In this case, the
trader makes a profit, or loss, by forecasting whether the leading
cryptocurrency of the pair will gain or lose value against its cryptocurrency
partner
7.1 Crypto price chart
1.Crypto charts are graphical representations of historical price,
volumes, and time intervals. The charts form patterns based on
the past price movements of the digital currency and are used to
spot investment opportunities.
2.A Candlestick is among the frequently used charts by crypto
traders. To interpret the image above, you should be aware that a
candle is represented in red when the closing price is lower than
the starting price during a specified time frame. This means the
price of the asset declined. In contrast, the green candle shows
that the closing price was greater than the starting price. This
indicates that the asset’s price rose. These candlestick charts form
several patterns. Depending on the shape, colour and size of the
candlestick, traders take positions or make changes in their
trading strategies.
7.2 Candlesticks in crypto
The candlestick's shadows show the day's high and
low and how they compare to the open and close. A
candlestick's shape varies based on the relationship
between the day's high, low, opening and closing
prices.

Candlestick patterns are used to predict the future


direction of price movement. Discover 16 of the most
common candlestick patterns and how you can use
them to identify trading opportunities.
8.How this live price tracker helps in
trading?
• A live price tracking is basically a list of top 100 crypto that an investor watches with an eye
toward taking advantage of prices if they fall enough to create an interesting undervalued
situation. This takes the "closely followed" list a step further. These are names that an investor
would be prepared to buy and own at the right price or with the right catalyst (a sign that growth
has reignited, for instance).
• An investor or trader may create a watchlist of several, dozens, or even hundreds of trading
instruments to make more informed investment decisions. A watchlist can help an investor
track companies and stay abreast of financial or other news that could impact these instruments.
• Typically, the investor monitors the list, waiting for certain criteria to be met, such as trading,
over a certain volume, breaking out of a 52-week range, or moving above its 200-day moving
average, before placing trade orders
• These lists are used in cryptocurrency trading, where sharp price swings can sometimes offer
brief opportunities for high profits. In addition to trading metrics, a watchlist for cryptocurrencies
might track tokens with an upcoming fork or mainnet launch
• It’s a good idea to devote at least one screen entirely to watchlist tickers, with each entry
displaying just two or three fields, including last price, net change, and percentage change.
Some traders add a single chart to this linking the tickers to allow a quick review of price
patterns during the trading day
9.Why should one invest in crypto?
• This potential makes for an attractive investment to people who believe in the future
of digital currencies. For people who believe in that promise, investing in
cryptocurrency represents a way to earn high returns while supporting the future of
technology
• Invest in cryptocurrency is the desire for a reliable, long-term store of value. Unlike 
fiat money, most cryptocurrencies have a limited supply, capped by mathematical
algorithms. This makes it impossible for any political body or government agency to
dilute their value through inflation. Moreover, due to the cryptographic nature of
cryptocurrencies, it is impossible for a government body to tax or confiscate tokens
without the cooperation of the owner
• As a new technology, some speculative behavior is to be expected in the
cryptocurrency space, especially as blockchain technology matures
• One of the most impressive and unique aspects of cryptocurrency is also a significant
liability. Since cryptocurrency does not rely on a central intermediary, it falls on the
user to safely store the cryptographic keys which control their blockchain address
• As of 2022, estimated global crypto ownership rates at an average of 4.2%, with over
320 million crypto users worldwide and this number is expected to grow more in future
which can make the price of crypto much higher
10.SOURCE CODE
import requests
from bs4 import BeautifulSoup
import tkinter as tk
from tkinter import ttk
from tkinter import font as tkFont
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
import time

driver_path = input('Enter chrome driver path: ')

# Function to scrape stock data from generated URL


def scraper():
url = 'https://www.cointracker.io/price'
driver = webdriver.Chrome(driver_path)
driver.get(url)

# Wait for results to load


time.sleep(5)
html = driver.page_source

# Start scraping resultant html data


soup = BeautifulSoup(html, 'html.parser')

# Find the crypto price table to scrape


results = soup.find("table", {"class": 'table mx-auto'})
rows = results.findChildren('tr')
table_data = []
row_values = []

# Append individual cryptocurrency data into a list


for row in rows: cells = row.findChildren(['th', 'td'])
for cell in cells:
value = cell.text.strip()
value = " ".join(value.split())
row_values.append(value)
table_data.append(row_values)
row_values = []

# Formatting the cryptocurrency data stored in the list


stocks_data = ""
for stock in table_data:
single_record = ""
for cell in stock:
format_cell = "{:<30}"
single_record += format_cell.format(cell[:20])
single_record += "\n"
stocks_data += single_record

# Adding the formatted data into tkinter GUI


query_label.config(state=tk.NORMAL)
query_label.delete(1.0, "end")
query_label.insert(1.0, stocks_data)
query_label.config(state=tk.DISABLED)
driver.close()

# Creating tkinter window


window = tk.Tk()
window.title('Cryptocurrency Price Checker')
window.geometry('1200x1000')
window.configure(bg='white')
style = ttk.Style()
style.configure('my.TButton', font=('Helvetica', 16))
style.configure('my.TFrame', background='white')

# label text for title


ttk.Label(window, text="Cryptocurrency Price Checker",
background='white', foreground="DodgerBlue2",
font=("Helvetica", 30, 'bold')).grid(row=0, column=3, padx=300)

submit_btn = ttk.Button(window, text="Fetch Live Price!",


style='my.TButton', command=scraper)
submit_btn.grid(row=5, column=3, pady=5, padx=15, ipadx=5)

frame = ttk.Frame(window, style='my.TFrame')


frame.place(relx=0.50, rely=0.12, relwidth=0.98, relheight=0.90, anchor="n")

# To display stock data


query_label = tk.Text(frame, height="52", width="500", bg="lightskyblue1")
query_label.grid(row=7, columnspan=2)

window.mainloop()
RESULT/TESTING

You might also like