code: def __init__(
      self, parent=None, background="default", plotItem=None, **kargs
  ):
      ## start by instantiating the plotItem attribute in order to avoid recursive
      ## calls of PlotWidget.__getattr__ - which access self.plotItem!
      self.plotItem = None
      """When initializing PlotWidget, *parent* and *background* are passed to 
          :func:`GraphicsWidget.__init__() <pyqtgraph.GraphicsWidget.__init__>`
          and all others are passed
          to :func:`PlotItem.__init__() <pyqtgraph.PlotItem.__init__>`."""
      GraphicsView.__init__(self, parent, background=background)
      self.setSizePolicy(
          QtWidgets.QSizePolicy.Policy.Expanding,
          QtWidgets.QSizePolicy.Policy.Expanding,
      )
      self.enableMouse(False)
      if plotItem is None:
          self.plotItem = PlotItem(**kargs)
      else:
          self.plotItem = plotItem
      self.setCentralItem(self.plotItem)
      ## Explicitly wrap methods from plotItem
      ## NOTE: If you change this list, update the documentation above as well.
      for m in [
          "addItem",
          "removeItem",
          "autoRange",
          "clear",
          "setAxisItems",
          "setXRange",
          "setYRange",
          "setRange",
          "setAspectLocked",
          "setMouseEnabled",
          "setXLink",
          "setYLink",
          "enableAutoRange",
          "disableAutoRange",
          "setLimits",
          "register",
          "unregister",
          "viewRect",
      ]:
          setattr(self, m, getattr(self.plotItem, m))
      # QtCore.QObject.connect(self.plotItem, QtCore.SIGNAL('viewChanged'), self.viewChanged)
      self.plotItem.sigRangeChanged.connect(self.viewRangeChanged)
  
file_path: pyqtgraph/pyqtgraph/widgets/PlotWidget.py
imports: from ..graphicsItems.PlotItem import PlotItem
  from ..Qt import QtCore, QtWidgets
  from .GraphicsView import GraphicsView
label_desc: Use image node_id 1 to create a new PlotWidget object from inherited base classes: GraphicsView with example: obj = PlotWidget(parent, background, plotItem)