{
"info": {
"author": "Jean-Samuel Leboeuf",
"author_email": "jean-samuel.leboeuf.1@ulaval.ca",
"bugtrack_url": null,
"classifiers": [
"License :: OSI Approved :: MIT License",
"Operating System :: OS Independent",
"Programming Language :: Python :: 3"
],
"description": "# Python2LaTeX: The Python to LaTeX converter\n\nDid you ever feel overwhelmed by the cumbersomeness of LaTeX to produce quality tables and figures? Fear no more, Python2LaTeX is here! Produce perfect tables automatically and easily, create figures and plots that integrates seamlessly into your tex file, or even write your complete article directly from Python! All that effortlessly (or almost) with Python2LaTeX.\n\n## Prerequisites\n\nThe package makes use of numpy and assumes a distribution of LaTeX that uses ``pdflatex`` is installed on your computer. Some LaTeX packages are used, such as ``booktabs``, ``tikz``, ``pgfplots`` and ``pgfplotstable``. Your LaTeX distribution should inform you if such package needs to be installed.\n\n## Installation\n\nTo install the package, simply run in your terminal the command\n\n pip install python2latex\n\n## Examples\n\n### Create a simple document\n\nThe following example shows how to create a document with a single section and some text.\n```python\nfrom python2latex import Document\n\ndoc = Document(filename='simple_document_example', filepath='./examples/simple document example', doc_type='article', options=('12pt',))\ndoc.set_margins(top='3cm', bottom='3cm', margins='2cm')\nsec = doc.new_section('Spam and Egg', label='spam_egg')\nsec.add_text('The Monty Python slays the Spam and eats the Egg.')\n\ntex = doc.build() # Builds to tex and compile to pdf\nprint(tex) # Prints the tex string that generated the pdf\n```\n\n \n\n Click to unfold result \n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n