Example of CSVF Table

Given the csv file:

"Name","Age","Folly","Date"
"Harry",12,"Eating worms","2009-07-15"
"Jane",14,"Running fast","2010-01-11"
"Bob",48,"Driving range","1998-08-21"
"Sue",32,"Epicurial facilitation","2011-04-15"
"Rene",36,"Speed","2009-07-12"

We can use the csvftable directive to render only a portion of the table and specify the ordering of columns. For example:

.. csvftable:: Example of CSVF table
   :header-rows: 1
   :widths: 10 10 20
   :columns: 1 2 3
   :file: csv-data/example.csv

renders as:

Example of CSVF table
Name Age Folly
Harry 12 Eating worms
Jane 14 Running fast
Bob 48 Driving range
Sue 32 Epicurial facilitation
Rene 36 Speed

and:

.. csvftable:: Example of CSVF table
   :header-rows: 1
   :widths: 20 10 10 10
   :columns: 3 2 1 4
   :file: csv-data/example.csv

renders as:

Example of CSVF table
Folly Age Name Date
Eating worms 12 Harry 2009-07-15
Running fast 14 Jane 2010-01-11
Driving range 48 Bob 1998-08-21
Epicurial facilitation 32 Sue 2011-04-15
Speed 36 Rene 2009-07-12

Previous topic

Welcome to CSVFTable Directive’s documentation!

This Page