Python3 package to create Venn diagrams with 2-4 sets.
Project description
Venny4Py
Simple Venn diagrams for Python 3, up to 4 sets (for more than 4 sets it is better to use UpSet plot). It will take as input a dictionary of 2-4 sets and produce a venn diagram and a txt file with element intersections.
Dependencies:
- itertools
- matplotlib
Installation:
pip install venny4py
When installed, import:
from venny4py.venny4py import *
#dict of sets
sets = {
'Set1': set(list("Harry Potter")),
'Set2': set(list("Hermione Granger")),
'Set3': set(list("Ron Weasley")),
'Set4': set(list("Severus Snape"))
}
venny4py(sets=sets)
Parameters:
- sets - disctionary of sets (required)
- out - directory to output files, default current directory
- asax - if diagram should be plotted as subplot, then provide matplotlib ax here. Default is 'False' which will plot new figure
- ext - image extension, default is 'png'.
- dpi - image resolution, default is 300 dpi.
- size - image size in inches, default is 3.5. If using custom ax through "asax" parameter, specify approximate size of subplot in inches since fontsize is dependent on this parameter.
Check "Examples.ipynb" https://github.com/timyerg/venny4py/blob/main/Examples.ipynb to see some examples.
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
venny4py-1.0.3.tar.gz
(219.8 kB
view details)
Built Distribution
File details
Details for the file venny4py-1.0.3.tar.gz
.
File metadata
- Download URL: venny4py-1.0.3.tar.gz
- Upload date:
- Size: 219.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 14e1ee3bc08bd94517c7857d970f10d2bec6ae0d3120b45f29d1a5cbff659c8b |
|
MD5 | 5b63cbfe12176b35568567a37f4959b7 |
|
BLAKE2b-256 | 2730d9deba8c88b4c0c00610db579a542a8a469cbf16097d86c30175c4a96f70 |
File details
Details for the file venny4py-1.0.3-py3-none-any.whl
.
File metadata
- Download URL: venny4py-1.0.3-py3-none-any.whl
- Upload date:
- Size: 4.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.10.14
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3af759dfa10a751b53f2597a539c51334226a532d5d48eea0da83eaab0b3d98e |
|
MD5 | f5b042b43ce2faa3a95afb3a00295a5c |
|
BLAKE2b-256 | 6e29dc645095e64cdf254bc39ce3a9f41b07389556fa892d974035d94b0e3b08 |