This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

rstSpreadsheet provides the spreadsheet directive for reStructuredText. You can use it from Docutils or Sphinx. Any python function/module can be used to calculate the cell value. Please see the documentation and examples

Install

pip install rstspreadsheet  # or
easy_install rstspreadsheet

Usage

Use as a standalone program:

python -m rstspreadsheet sample.rst sample.html

Or use as a sphinx extension by adding it to extensions:

extensions = [
    # other extensions...
    'rstspreadsheet']

Examples

Simple spreadsheet

You can do this simple calculation:

p q p and q not (p and q)
0 0 0 1
1 0 0 1
0 1 0 1
1 1 1 0

with this simple code:

.. spreadsheet::
   :eq: {2} = {0} and {1}
        {3} = int(not {2})

   === === ========= ===============
    p   q   p and q   not (p and q)
   === === ========= ===============
    0   0
    1   0
    0   1
    1   1
   === === ========= ===============

Spreadsheet with python functions

If you want to calculate some complicated math functions like this:

function argument expression result
fac 5 fac(5) 120.00
sin pi sin(pi) 0.00
cos pi cos(pi) -1.00
exp 1 exp(1) 2.72

use python module/function!:

.. spreadsheet::
   :eq: {2} = '{0}({1})'
        {3} = {2}
   :setup: from math import sin, cos, exp, pi
           def fac(n):
               return fac(n-1) * n if n > 1 else 1
   :format: 3:'%0.2f'

   ======== ======== ========== ======
   function argument expression result
   ======== ======== ========== ======
   fac      5
   sin      pi
   cos      pi
   exp      1
   ======== ======== ========== ======

You can see more examples here.

Release History

Release History

0.1.2

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
rstspreadsheet-0.1.2-py2.6.egg (11.8 kB) Copy SHA256 Checksum SHA256 2.6 Egg Jun 10, 2011
rstspreadsheet-0.1.2.tar.gz (5.3 kB) Copy SHA256 Checksum SHA256 Source Jun 10, 2011

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting