class_docstr: Widget to facilitate plotting
  
  Parameters
  ----------
  *args : arguments
      Arguments passed to the `ViewBox` super class.
  **kwargs : keywoard arguments
      Keyword arguments passed to the `ViewBox` super class.
  
  Notes
  -----
  This class is typically instantiated implicitly by a `Figure`
  instance, e.g., by doing ``fig[0, 0]``.
class_docstr_tok: ["Widget","to","facilitate","plotting","Parameters","--","--","--","--","--","*","args",":","arguments","Arguments","passed","to","the","`","ViewBox","`","super","class",".","*","*","kwargs",":","keywoard","arguments","Keyword","arguments","passed","to","the","`","ViewBox","`","super","class",".","Notes","--","--","-","This","class","is","typically","instantiated","implicitly","by","a","`","Figure","`","instance",",","e.g.",",","by","doing","``","fig","[","0",",","0","]","``","."]
docstr: Calculate and show a histogram of data
  
  Parameters
  ----------
  data : array-like
      Data to histogram. Currently only 1D data is supported.
  bins : int | array-like
      Number of bins, or bin edges.
  color : instance of Color
      Color of the histogram.
  orientation : {'h', 'v'}
      Orientation of the histogram.
  
  Returns
  -------
  hist : instance of Polygon
      The histogram polygon.
docstr_tok: ["Calculate","and","show","a","histogram","of","data","Parameters","--","--","--","--","--","data",":","array-like","Data","to","histogram",".","Currently","only","1D","data","is","supported",".","bins",":","int","|","array-like","Number","of","bins",",","or","bin","edges",".","color",":","instance","of","Color","Color","of","the","histogram",".","orientation",":","{","'","h","'",",","'","v","'","}","Orientation","of","the","histogram",".","Returns","--","--","--","-","hist",":","instance","of","Polygon","The","histogram","polygon","."]
code: def histogram(self, data, bins=10, color="w", orientation="h"):
      """Calculate and show a histogram of data
  
      Parameters
      ----------
      data : array-like
          Data to histogram. Currently only 1D data is supported.
      bins : int | array-like
          Number of bins, or bin edges.
      color : instance of Color
          Color of the histogram.
      orientation : {'h', 'v'}
          Orientation of the histogram.
  
      Returns
      -------
      hist : instance of Polygon
          The histogram polygon.
      """
      self._configure_2d()
      hist = scene.Histogram(data, bins, color, orientation)
      self.view.add(hist)
      self.view.camera.set_range()
      return hist
  
file_path: vispy/vispy/plot/plotwidget.py
imports: from ..None import scene
  from ..io import read_mesh
  from ..geometry import MeshData
label_desc: Use image node_id 4 for calling the PlotWidget obj's underlying member method code with example usage: obj.histogram(data, bins, color, orientation) and returns: hist