GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Table of Contents
  • wx.lib.plot.polyobjects.PolyHistogram
  • Show Source
  • index
  • modules
  • next
  • previous
  • Home
  • Gallery
  • wx.lib
  • wx.lib.plot
  • wx.lib.plot.polyobjects

This view

  • Original page
  • New address

GeezerVison is showing docs.wxpython.org — wx.lib.plot.polyobjects.PolyHistogram — wxPython 4.3.2 Docs

phoenix_title wx.lib.plot.polyobjects.PolyHistogram¶

Creates a PolyHistogram object.

param hist:

The histogram data.

type hist:

sequence of y values that define the heights of the bars

param binspec:

The bin specification.

type binspec:

sequence of x values that define the edges of the bins

param **attr:

keyword attributes

Keyword and Default

Description

Type

edgecolour='black'

edge color

wx.Colour

edgewidth=3

edge width

float

edgestyle=wx.PENSTYLE_SOLID

edge style

wx.PenStyle

fillcolour='blue'

fill color

wx.Colour

fillstyle=wx.BRUSHSTYLE_SOLID

fill style

wx.BrushStyle

legend=''

legend string

str

Tip

Use np.histogram() to easily create your histogram parameters:

hist_data, binspec = np.histogram(data)
hist_plot = PolyHistogram(hist_data, binspec)

Important

len(binspec) must equal len(hist) + 1.

Warning

All methods except __init__ are private.


class_hierarchy Class Hierarchy¶

Inheritance diagram for class PolyHistogram:

Inheritance diagram of PolyHistogram


super_classes Known Superclasses¶

wx.lib.plot.polyobjects.PolyBarsBase


method_summary Methods Summary¶

__init__

calc_rect

Calculate the rectangle for plotting.

draw

Draw the bars


api Class API¶

class PolyHistogram(PolyBarsBase)¶

Creates a PolyHistogram object.

Parameters:
  • hist (sequence of y values that define the heights of the bars) – The histogram data.

  • binspec (sequence of x values that define the edges of the bins) – The bin specification.

  • **attr – keyword attributes

Keyword and Default

Description

Type

edgecolour='black'

edge color

wx.Colour

edgewidth=3

edge width

float

edgestyle=wx.PENSTYLE_SOLID

edge style

wx.PenStyle

fillcolour='blue'

fill color

wx.Colour

fillstyle=wx.BRUSHSTYLE_SOLID

fill style

wx.BrushStyle

legend=''

legend string

str

Tip

Use np.histogram() to easily create your histogram parameters:

hist_data, binspec = np.histogram(data)
hist_plot = PolyHistogram(hist_data, binspec)

Important

len(binspec) must equal len(hist) + 1.

Warning

All methods except __init__ are private.


Methods¶

__init__(self, hist, binspec, \*\*attr)¶


calc_rect(self, y, low, high)¶

Calculate the rectangle for plotting.



draw(self, dc, printerScale, coord=None)¶

Draw the bars

© Copyright 2012-2026, The wxPython Team. Created using Sphinx 9.1.0 and the python-docs-theme.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.