Add QT GUI to Python for plotting graphics Last Updated : 19 Feb, 2020 Comments Improve Suggest changes Like Article Like Report Qt framework (with QT Creator IDE) can be used to create a fancy interfaces for Python GUI application. Plotting graphics on a GUI is possible with pyqtgraph library. Installing pyqtgraph - There are several ways of installing pyqtgraph depending on your needs. If you are using Anaconda you can install with: conda install -c anaconda pyqtgraph Or with pip command: pip install pyqtgraph Creation of plot widgets with QT Creator - Add the buttons, text areas and other stuffs as usually done with QT Creator. To create a plot area you need to follow the steps: Add widget to UI and give it a proper name like "widgetSignal" Promote the widget to pyqtgraph Load UI to Python - In your python code call the UI you created with QT Creator. Create a sin wave for plotting Draw the graph on UI Python3 1== from PyQt5 import QtWidgets, uic import sys import numpy as np class MainWindow(QtWidgets.QMainWindow): def __init__(self, *args, **kwargs): super(MainWindow, self).__init__(*args, **kwargs) # Load the UI Page self. ui = uic.loadUi('mainwindow.ui', self) # Create a sin wave x_time = np.arange(0, 100, 0.1); y_amplitude = np.sin(x_time) pltSignal = self.widgetSignal pltSignal.clear() pltSignal.setLabel('left', 'Signal Sin Wave', units ='(V)') pltSignal.setLabel('bottom', 'Time', units ='(sec)') pltSignal.plot(x_time, y_amplitude, clear = True) self.ui.show() def main(): app = QtWidgets.QApplication(sys.argv) window = MainWindow() sys.exit(app.exec_()) if __name__ == '__main__': main() Output: Comment More infoAdvertise with us Next Article Add QT GUI to Python for plotting graphics E embeddedEngineerGirl Follow Improve Article Tags : Technical Scripter Python Technical Scripter 2019 Python-PyQt Python-gui +1 More Practice Tags : python Similar Reads Graph Plotting in Python | Set 1 This series will introduce you to graphing in Python with Matplotlib, which is arguably the most popular graphing and data visualization library for Python.InstallationThe easiest way to install matplotlib is to use pip. Type the following command in the terminal:Â pip install matplotlibOR, you can d 9 min read Grammar of Graphics for Python: An Introduction to Plotline A grammar of graphics is basically a tool that enables us to describe the components of a given graphic. Basically, what this allows us to see beyond the named graphics, (scatter plot, to name one) and to basically see the underlying statistics behind it. The grammar of graphics was originally intro 6 min read How to add a grid on a figure in Matplotlib ? Matplotlib library is widely used for plotting graphs. In many graphs, we require to have a grid to improve readability. Grids are created by using grid() function in the Pyplot sublibrary. In this article, we will see how to add grid in Matplotlb. Add a Grid on a Figure in MatplotlibBelow are the w 3 min read How to add Matplotlib graph in Kivy ? In this article, we will discuss how to add matplotlib graph in the kivy app. Approach:Import matplotlib pyplotImport numpyImport FigureCanvas KivyAggImport kivy appImport kivy builderCreate App classReturn builder stringRun an instance of the class Below is the Implementation. Python3 # importing p 2 min read Matplotlib.figure.Figure.set_canvas() in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. The figure module provides the top-level Artist, the Figure, which contains all the plot elements. This module is used to control the default spacing of the subplots and top level container for all plot 2 min read How to add text to Matplotlib? Matplotlib is a plotting library in Python to visualize data, inspired by MATLAB, meaning that the terms used (Axis, Figure, Plots) will be similar to those used in MATLAB. Pyplot is a module within the Matplotlib library which is a shell-like interface to Matplotlib module. Â It provides almost any 5 min read Matplotlib.figure.Figure.ginput() in Python Matplotlib is a library in Python and it is numerical â mathematical extension for NumPy library. The figure module provides the top-level Artist, the Figure, which contains all the plot elements. This module is used to control the default spacing of the subplots and top level container for all plot 2 min read PyQtGraph â Getting Cursor to Scatter Plot Graph In this article, we will see how we can get a custom cursor to the scatter plot graph in the PyQtGraph module. PyQtGraph is a graphics and user interface library for Python that provides functionality commonly required in designing and science applications. Its primary goals are to provide fast, int 3 min read PyQtGraph â Setting Cursor to Scatter Plot Graph In this article, we will see how we can set a custom cursor to the scatter plot graph in the PyQtGraph module. PyQtGraph is a graphics and user interface library for Python that provides functionality commonly required in designing and science applications. Its primary goals are to provide fast, int 3 min read PyQtGraph - Adding Item to Plot Window In this article we will see how we can add item to the plot window in the PyQtGraph module. PyQtGraph is a graphics and user interface library for Python that provides functionality commonly required in designing and science applications. Its primary goals are to provide fast, interactive graphics f 2 min read Like