Skip to main content

Minimal graph renderer for fixed size canvas

Project description

Python Package Build Status Dependency Status Code Quality Test Coverage License

Minimal chart renderer for fixed size canvas for Python.

Installation

pip install tchart

Usage

  • simple way:

    from tchart import Tchart
    
    t = Tchart(height=10, width=80)
    
    data = [12.1, -2, 100]
    chart = t.render(data)
    
    print('\n'.join(chart))
  • extended way:

    from tchart import Tchart
    from tchart.renderers import BoxRenderer
    from tchart.decorators import AxisDecorator
    
    t = Tchart(height=10, width=80, renderer=BoxRenderer(), decorators=[AxisDecorator(), ])
    
    data = [12.1, -2, 100]
    chart = t.render(data)
    
    print('\n'.join(chart))

Examples

Please check the examples directory.

  • examples/show_all_renderers.py

    Renderers

  • examples/show_all_decorators.py

    Decorators

  • examples/show_stacked_decorators.py

    StackedDecorators

Bugs

Bugs or suggestions? Visit the issue tracker.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tchart-2.0.0.tar.gz (18.3 kB view hashes)

Uploaded Source

Built Distribution

tchart-2.0.0-py2.py3-none-any.whl (8.2 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page