cmck / python-tabulate

MIT License
5 stars 1 forks source link

add terminaltables benchmark #2

Open anarcat opened 4 years ago

anarcat commented 4 years ago

The result of this here looks like this:

===========================  ==========  ===========
Table formatter                time, μs    rel. time
===========================  ==========  ===========
csv to StringIO                    14.7          1.0
join with tabs and newlines        20.3          1.4
asciitable (0.8.0)                338.4         23.0
tabulate (0.8.3)                  725.3         49.3
terminaltables (3.1.0)            806.5         54.8
PrettyTable (0.7.2)              1364.5         92.7
texttable (1.6.2)                2044.0        138.8
===========================  ==========  ===========

ie. it is very close to tabulate's results in terms of performance, although it doesn't have the flexibility of tabulate in terms of output formats.

anarcat commented 4 years ago

also note that we just test one of the output formats above, we might want to see if the other perform differently?