{ "info": { "author": "Blair Bonnett", "author_email": "blair.bonnett@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "Intended Audience :: Science/Research", "License :: OSI Approved :: BSD License", "Programming Language :: Python", "Topic :: Scientific/Engineering :: Visualization" ], "description": "pgfutils\n========\n\nThe [Portable Graphics Format (PGF)][1] is a language for producing vector\ngraphics within TeX documents. There is also a higher-level language TikZ (TikZ\nist kein Zeichenprogramm -- TikZ is not a drawing program) which uses PGF.\n\nSince version 1.2, the Python plotting library [Matplotlib][2] has included a\nPGF backend to generate figures ready for inclusion in a TeX document. In order\nto get consistent figures that fit with the style of the document, this\nrequires some configuration. The aim of pgfutils is to simplify this\nconfiguration and allow figures to be easily generated from a Python script.\n\nThe module provides two functions which set up and then save the figure. The\nactual plotting is performed by standard Matplotlib functions. For example, to\ngenerate a plot showing the 1st, 3rd, 5th, 7th, 9th and 11th harmonics of an\nideal square wave and the resulting sum:\n\n```python\n# Set up the figure environment.\nfrom pgfutils import setup_figure, save\nsetup_figure(width=0.9, height=0.4)\n\nimport numpy as np\nfrom matplotlib import pyplot as plt\n\n# Generate square wave from a few terms of its Fourier series.\nf = 3\nt = np.linspace(0, 1, 501)\nsquare = np.zeros(t.shape)\nfor n in range(1, 12, 2):\n # Create this harmonic and plot it as a dashed\n # partially-transparent line.\n component = np.sin(2 * n * np.pi * f * t) / n\n plt.plot(t, component, '--', alpha=0.4)\n\n # Add it to the overall signal.\n square += component\n\n# Scale the final sum.\nsquare *= 4 / np.pi\n\n# Plot and label the figure.\nplt.plot(t, square, 'C0')\nplt.xlim(0, 1)\nplt.ylim(-1.2, 1.2)\nplt.xlabel(\"Time (s)\")\nplt.ylabel(\"Amplitude (V)\")\n\n# Save as a PGF image.\nsave()\n```\n\n[1]: https://sourceforge.net/projects/pgf/\n[2]: https://matplotlib.org/\n\n\nRequirements\n------------\n\nUsing pgfutils requires Python 3. Each commit is currently tested with release\nversions of Python 3.6 and 3.7, as well as a development version of Python 3.8.\n\nThe only external dependency is matplotlib. All the other dependencies are part\nof the standard Python library.\n\n\nExamples\n--------\n\npgfutils comes with some examples which demonstrate its usage and integration\ninto a build system. Depending on your installation method, these may be\npresent somewhere in your filesystem (e.g., on a Linux system, they might be at\n`/usr/share/matplotlib-pgfutils/examples`). They can also be found in the\n[extras/examples directory](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/extras/examples).\n\n\nDocumentation\n-------------\n\nDocumentation for pgfutils can be found online at\nhttps://matplotlib-pgfutils.readthedocs.io/\n\nAlternatively, you can find the source of this documentation in Markdown format\nin the doc/ directory of the source:\n\n* [Usage](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/doc/usage.md)\n* [Configuration](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/doc/config.md)\n* [Interactive mode](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/doc/interactive.md)\n* [File tracking](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/doc/file_tracking.md)\n* [Latexmk integration](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/doc/latexmk.md)\n\nAn example configuration file showing the default settings is given in\n[extras/pgfutils.cfg](https://github.com/bcbnz/matplotlib-pgfutils/blob/master/extras/pgfutils.cfg).\n\n\nUnit testing\n------------\n\n[![Build Status](https://travis-ci.com/bcbnz/matplotlib-pgfutils.svg?branch=master)](https://travis-ci.com/bcbnz/matplotlib-pgfutils)\n[![codecov](https://codecov.io/gh/bcbnz/matplotlib-pgfutils/branch/master/graph/badge.svg)](https://codecov.io/gh/bcbnz/matplotlib-pgfutils)\n\nExtensive unit tests are included in the tests/ directory of the source. Each\ncommit to the source repository is automatically tested thanks to [Travis\nCI][3]. The test coverage (that is, how many of the lines of code in the source\nwere executed during the tests) is monitored by [Codecov][4]. The badges above\nshow the status of the last commit made to the source.\n\nYou can also run the tests on a local copy of the code. They are designed to be\nrun with the [pytest][5] framework and employ the [Coverage.py][6] package via\nthe [pytest-cov][7] plugin to measure the coverage. If you have these packages\ninstalled, run `pytest` from the top-level directory to execute the tests. A\nbasic test coverage report will be printed on the terminal, and the full report\ncan be viewed by opening the `htmlcov/index.html` file in your web browser.\n\n[3]: https://travis-ci.com/bcbnz/matplotlib-pgfutils\n[4]: https://codecov.io/gh/bcbnz/matplotlib-pgfutils\n[5]: https://pytest.org/\n[6]: https://coverage.readthedocs.io/\n[7]: https://pytest-cov.readthedocs.io/\n\n\nLicense\n-------\n\npgfutils is released under the three-clause BSD license. The terms of this\nlicense can be found in the LICENSE file in the source, or online at\nhttps://opensource.org/licenses/BSD-3-Clause\n\nThe Cotham Sans font used in some unit tests is copyright (c) 2015 Sebastien\nSanfilippo and is licensed under the SIL Open Font License, Version 1.1. The\nlicense can be found in the source at tests/sources/fonts/Cotham/OFL.txt or\nonline at https://scripts.sil.org/OFL and the font itself can be found at\nhttps://github.com/sebsan/Cotham\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/bcbnz/matplotlib-pgfutils", "keywords": "", "license": "BSD", "maintainer": "", "maintainer_email": "", "name": "matplotlib-pgfutils", "package_url": "https://pypi.org/project/matplotlib-pgfutils/", "platform": "", "project_url": "https://pypi.org/project/matplotlib-pgfutils/", "project_urls": { "Homepage": "https://github.com/bcbnz/matplotlib-pgfutils" }, "release_url": "https://pypi.org/project/matplotlib-pgfutils/1.3.1/", "requires_dist": [ "matplotlib (>=1.2)" ], "requires_python": "", "summary": "Utilities for generating PGF figures from Matplotlib", "version": "1.3.1" }, "last_serial": 5966935, "releases": { "1.0.0": [ { "comment_text": "", "digests": { "md5": "edd2b0ec261134b69f76ce6e76785ac1", "sha256": "301bd9935a81cd851e0c430897c9a2088a6bea356bb7aeb29f511cda8e0f106e" }, "downloads": -1, "filename": "matplotlib_pgfutils-1.0.0-py3-none-any.whl", "has_sig": false, "md5_digest": "edd2b0ec261134b69f76ce6e76785ac1", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 25132, "upload_time": "2019-04-21T15:13:16", "url": "https://files.pythonhosted.org/packages/36/47/119655b6625d6899d4a0c3646b36e10069cf1c7daa63243a193da7592991/matplotlib_pgfutils-1.0.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "63b6dfa2779d6111f1a0a0f787a72d86", "sha256": "2717a1741d62b519d4615d9bf7806c70dbe54b45a65e2a426a0ac169582f3e3e" }, "downloads": -1, "filename": "matplotlib-pgfutils-1.0.0.tar.gz", "has_sig": false, "md5_digest": "63b6dfa2779d6111f1a0a0f787a72d86", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 20092, "upload_time": "2019-04-21T15:13:18", "url": "https://files.pythonhosted.org/packages/73/f3/8a1d24745f868758de826f0609acb2671f9828642fc281c5b9cd412d8e33/matplotlib-pgfutils-1.0.0.tar.gz" } ], "1.1.0": [ { "comment_text": "", "digests": { "md5": "d4777d4d13061cc483b6aece59b051c6", "sha256": "a6b4107d17eb158a5b5219fa07b936ab0f2d6a6b08805891d0061441dbacfd62" }, "downloads": -1, "filename": "matplotlib_pgfutils-1.1.0-py3-none-any.whl", "has_sig": false, "md5_digest": "d4777d4d13061cc483b6aece59b051c6", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 25452, "upload_time": "2019-07-25T12:40:08", "url": "https://files.pythonhosted.org/packages/98/ea/ebdaec86d84146886626042ae24d143efd4995295e7df846a19aa9de0db0/matplotlib_pgfutils-1.1.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "1e56841cf9b9ca7393f9ff28b99a2aa8", "sha256": "007e31bd4dcaa2bbf329a67514d780e83fc3266895284dcf5553cc9a14fe097e" }, "downloads": -1, "filename": "matplotlib-pgfutils-1.1.0.tar.gz", "has_sig": false, "md5_digest": "1e56841cf9b9ca7393f9ff28b99a2aa8", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 20445, "upload_time": "2019-07-25T12:40:10", "url": "https://files.pythonhosted.org/packages/8e/07/46f035ba4eef6a5a854d5730fbaefa2eea235c71866a436fdd812214c64c/matplotlib-pgfutils-1.1.0.tar.gz" } ], "1.2.0": [ { "comment_text": "", "digests": { "md5": "17f7f215dcc7b1b3880c3fcddfb0c2a4", "sha256": "fc6dd984c55b00cace1e3d8d19762f7d22d91d4afd508bc210acecbe5ff83803" }, "downloads": -1, "filename": "matplotlib_pgfutils-1.2.0-py3-none-any.whl", "has_sig": false, "md5_digest": "17f7f215dcc7b1b3880c3fcddfb0c2a4", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 25575, "upload_time": "2019-10-08T12:06:50", "url": "https://files.pythonhosted.org/packages/f5/2b/3bc9038a2aa25548e26214cb6ccbb65f32d2abd9f5d0623715a6ac3eed1b/matplotlib_pgfutils-1.2.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "3d358b73fa7e630956f3822015f05d18", "sha256": "77559ce1984c087bd13ec50114bf6e55e22f88b2206a87dcfe032fcfc8b7c42b" }, "downloads": -1, "filename": "matplotlib-pgfutils-1.2.0.tar.gz", "has_sig": false, "md5_digest": "3d358b73fa7e630956f3822015f05d18", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 20572, "upload_time": "2019-10-08T12:06:52", "url": "https://files.pythonhosted.org/packages/04/a4/0479fa138219eaf8aed822f8ccbdb9683b4fcf0a92390f5ae0ea2a05cf8c/matplotlib-pgfutils-1.2.0.tar.gz" } ], "1.3.0": [ { "comment_text": "", "digests": { "md5": "c420242704fcf8160fe45749e9067717", "sha256": "a2cd0e747b91dcf8a07f89fcd5525376efceb5a8d538c2a1aa52d5bbf538c927" }, "downloads": -1, "filename": "matplotlib_pgfutils-1.3.0-py3-none-any.whl", "has_sig": false, "md5_digest": "c420242704fcf8160fe45749e9067717", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26308, "upload_time": "2019-10-13T09:23:49", "url": "https://files.pythonhosted.org/packages/d5/4a/9202c13bca385d31a8f5a9709463d77f11b4c50bf521ca760360e670087a/matplotlib_pgfutils-1.3.0-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "460d420ab0493cac06c25acaaa3fbf47", "sha256": "fc0368db98a8a886af23150314fc4a68f8e95baa3f390165d1a079ed8a5838cd" }, "downloads": -1, "filename": "matplotlib-pgfutils-1.3.0.tar.gz", "has_sig": false, "md5_digest": "460d420ab0493cac06c25acaaa3fbf47", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21340, "upload_time": "2019-10-13T09:23:52", "url": "https://files.pythonhosted.org/packages/b9/07/61a7cfdfe20c4a1f573755114040643fd095e7343f3a8ed81e098e4db21d/matplotlib-pgfutils-1.3.0.tar.gz" } ], "1.3.1": [ { "comment_text": "", "digests": { "md5": "ef64edc4fe07e53ac00f101cbe03d9d7", "sha256": "95f5b7178840edb440a8a7ee9351a2fd2490e8fb2971c1fa5ecd9666cad7a2e0" }, "downloads": -1, "filename": "matplotlib_pgfutils-1.3.1-py3-none-any.whl", "has_sig": false, "md5_digest": "ef64edc4fe07e53ac00f101cbe03d9d7", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26306, "upload_time": "2019-10-13T09:39:08", "url": "https://files.pythonhosted.org/packages/f4/6c/193ba60373f77e012d54b1fa4c22515830493014e5f30c1e094e05e119ef/matplotlib_pgfutils-1.3.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "34653ab8b3afe7bfce6a35d79150592d", "sha256": "7aa05c3b3ef6e06d254fa73a84f554b3c4efa6751ee9b817a482fafd00b84271" }, "downloads": -1, "filename": "matplotlib-pgfutils-1.3.1.tar.gz", "has_sig": false, "md5_digest": "34653ab8b3afe7bfce6a35d79150592d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21342, "upload_time": "2019-10-13T09:39:10", "url": "https://files.pythonhosted.org/packages/e4/95/06a14c63aa18d2748c21e68f8e6bb23ec24f9c4658ea07e0d22c0e1e8dbb/matplotlib-pgfutils-1.3.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "ef64edc4fe07e53ac00f101cbe03d9d7", "sha256": "95f5b7178840edb440a8a7ee9351a2fd2490e8fb2971c1fa5ecd9666cad7a2e0" }, "downloads": -1, "filename": "matplotlib_pgfutils-1.3.1-py3-none-any.whl", "has_sig": false, "md5_digest": "ef64edc4fe07e53ac00f101cbe03d9d7", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 26306, "upload_time": "2019-10-13T09:39:08", "url": "https://files.pythonhosted.org/packages/f4/6c/193ba60373f77e012d54b1fa4c22515830493014e5f30c1e094e05e119ef/matplotlib_pgfutils-1.3.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "34653ab8b3afe7bfce6a35d79150592d", "sha256": "7aa05c3b3ef6e06d254fa73a84f554b3c4efa6751ee9b817a482fafd00b84271" }, "downloads": -1, "filename": "matplotlib-pgfutils-1.3.1.tar.gz", "has_sig": false, "md5_digest": "34653ab8b3afe7bfce6a35d79150592d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 21342, "upload_time": "2019-10-13T09:39:10", "url": "https://files.pythonhosted.org/packages/e4/95/06a14c63aa18d2748c21e68f8e6bb23ec24f9c4658ea07e0d22c0e1e8dbb/matplotlib-pgfutils-1.3.1.tar.gz" } ] }