Get Corona cases details – Python PyQt5
In this article we will see how we can create a PyQt5 application which tells about the cases of corona around the world i.e number of confirmed cases, number of cases in which patient has recovered and total deaths due to corona.
Modules required and Installation:
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course. And to begin with your Machine Learning Journey, join the Machine Learning - Basic Level Course
PyQt5 : PyQt is a Python binding of the cross-platform GUI toolkit Qt, implemented as a Python plug-in. PyQt is free software developed by the British firm Riverbank Computing.
Requests : Requests allows you to send HTTP/1.1 requests extremely easily. There’s no need to manually add query strings to your URLs.
Beautiful Soup: Beautiful Soup is a library that makes it easy to scrape information from web pages. It sits atop an HTML or XML parser, providing Pythonic idioms for iterating, searching, and modifying the parse tree.
Implementations steps :
1. Create a push-button set its geometry
2. Create three labels to show information about total cases, recovered cases and death cases
3. Set geometry, alignment and border to each label
4. Add action to the push button
5. Inside the action scrap the data from the website with the help of requests BeautifulSoup
6. Convert the raw data into html code and then filter it to get the required output
7. Show the output the screen with the help of labels
Below is the implementation