{ "info": { "author": "Brent Pedersen", "author_email": "bpederse@gmail.com", "bugtrack_url": null, "classifiers": [ "Programming Language :: Python :: 2", "Programming Language :: Python :: 3", "Topic :: Scientific/Engineering :: Bio-Informatics" ], "description": "Cigar\n=====\n\ncigar is a simple library for dealing with cigar strings. the most useful\nfeature now is soft-masking from left or right. This allows one to adjust\na SAM record only by changing the cigar string to soft-mask a number of bases\nsuch that the rest of the SAM record (pos, tlen, etc.) remain valid, but\ndownstream tools will not consider the soft-masked bases in further analysis.\n\n\n```Python\n>>> from cigar import Cigar\n\n>>> c = Cigar('100M')\n>>> len(c)\n100\n>>> str(c)\n'100M'\n>>> list(c.items())\n[(100, 'M')]\n\n\n>>> c = Cigar('20H20M20S')\n>>> len(c)\n40\n>>> str(c)\n'20H20M20S'\n>>> list(c.items())\n[(20, 'H'), (20, 'M'), (20, 'S')]\n\n>>> c.mask_left(29).cigar, c.cigar\n('20H9S11M20S', '20H20M20S')\n\n>>> c = Cigar('10M20S10M')\n>>> c.mask_left(10).cigar\n'30S10M'\n>>> c.mask_left(9).cigar\n'9S1M20S10M'\n>>> Cigar('10S').mask_left(10).cigar\n'10S'\n>>> Cigar('10H').mask_left(10).cigar\n'10H'\n>>> Cigar('10H').mask_left(11).cigar\n'10H'\n>>> Cigar('10H').mask_left(9).cigar\n'10H'\n\n>>> Cigar('1M10H').mask_left(9).cigar\n'1S10H'\n\n>>> Cigar('5M10H').mask_left(9).cigar\n'5S10H'\n\n>>> c = Cigar('1S1H1S5H1S5M10H')\n>>> c.mask_left(9).cigar == c.cigar\nTrue\n\n>>> c = Cigar('1S1H1S5H1S5M10H')\n>>> c.mask_right(9).cigar == c.cigar\nTrue\n>>> c.mask_right(11).cigar\n'1S1H1S5H1S4M1S10H'\n\n```\n\nInstallation\n============\n\n pip install cigar", "description_content_type": null, "docs_url": null, "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/brentp/cigar", "keywords": null, "license": "MIT", "maintainer": null, "maintainer_email": null, "name": "cigar", "package_url": "https://pypi.org/project/cigar/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/cigar/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/brentp/cigar" }, "release_url": "https://pypi.org/project/cigar/0.1.3/", "requires_dist": null, "requires_python": null, "summary": "manipulate SAM cigar strings", "version": "0.1.3" }, "last_serial": 1852651, "releases": { "0.1": [ { "comment_text": "", "digests": { "md5": "991886d9bf46d7ea2e9373472caf791b", "sha256": "b34049473cded58be400979632abe23177ca291e72c36c115eb0fed715e4e267" }, "downloads": -1, "filename": "cigar-0.1.tar.gz", "has_sig": false, "md5_digest": "991886d9bf46d7ea2e9373472caf791b", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 2610, "upload_time": "2014-07-12T13:15:03", "url": "https://files.pythonhosted.org/packages/33/67/f637e32bf10da470076f85d2caa1143d478fd8e79f383f0c6b667ae19c3b/cigar-0.1.tar.gz" } ], "0.1.2": [ { "comment_text": "", "digests": { "md5": "984356f6cbfe7334ad74692f7c2684ed", "sha256": "ff6c72abb00fc59519a528e0fc33f536d8357123f490b1f01bab40352b266dd9" }, "downloads": -1, "filename": "cigar-0.1.2.tar.gz", "has_sig": false, "md5_digest": "984356f6cbfe7334ad74692f7c2684ed", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 3589, "upload_time": "2015-12-08T18:48:50", "url": "https://files.pythonhosted.org/packages/f2/83/2e4c1cefbc3172b62193705b990b1483f848b10f714a3771c1532fc6759c/cigar-0.1.2.tar.gz" } ], "0.1.3": [ { "comment_text": "", "digests": { "md5": "5c8d8ca31d80d759f67d87dcd54ec01d", "sha256": "5847f5e8968035b3a5b04dcfa879fb6c14dd3a42dce8994864806dcda8a4fcf2" }, "downloads": -1, "filename": "cigar-0.1.3.tar.gz", "has_sig": false, "md5_digest": "5c8d8ca31d80d759f67d87dcd54ec01d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7029, "upload_time": "2015-12-08T18:49:31", "url": "https://files.pythonhosted.org/packages/2d/5f/ffa58a8c64f811772b69a01eeab25c602b72d02a0c83006177c21abedaa3/cigar-0.1.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "5c8d8ca31d80d759f67d87dcd54ec01d", "sha256": "5847f5e8968035b3a5b04dcfa879fb6c14dd3a42dce8994864806dcda8a4fcf2" }, "downloads": -1, "filename": "cigar-0.1.3.tar.gz", "has_sig": false, "md5_digest": "5c8d8ca31d80d759f67d87dcd54ec01d", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 7029, "upload_time": "2015-12-08T18:49:31", "url": "https://files.pythonhosted.org/packages/2d/5f/ffa58a8c64f811772b69a01eeab25c602b72d02a0c83006177c21abedaa3/cigar-0.1.3.tar.gz" } ] }