{ "info": { "author": "Liam McCluskey", "author_email": "lmm459@rutgers.edu", "bugtrack_url": null, "classifiers": [ "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3" ], "description": "#number_line\n\nThe number_line python package allows users to create a number line (as an object) to which they can add or remove points and ranges, and perform many other functions. The sections below explain how to use this package.\n\n---\n##Importing this Package\n\nOnce you have installed this package, you can import it. In order to import this package for use within a file, type the code shown below.\n```python\nfrom number_line import NumberLine\n```\n\n---\n##Creating a NumberLine Object\n\nOnce you have imported this package, you can create a NumberLine object. In order to do this, type the code show below.\n```python\nnl = NumberLine()\n```\nSince objects of type NumberLine do not take any input parameters, you should not pass any arguments when instantiating the class.\n\n---\n##Adding a Point to the Number Line\n\n**Method to Use: ** add_point(pointVal)\n\n**Return Type: ** None\n\n**Arguments (listed in the order in which they should be passed in): **\n\n1. pointVal (Type: Numeric): This argument is the value of the point you want to add to the number line.\n\nOnce you have created a NumberLine object, you can add a point to it. When adding a point to the number line, you must use the add_point() method and pass in the argument listed above. In order to do this for sample points of 1 and 2, type the code shown below.\n```python\nnl.add_point(1)\nnl.add_point(2)\n```\nThe code above will add points at 1 and 2 to the NumberLine object you created in the section above.\n\n---\n##Removing a Point from the Number Line\n\n**Method to Use: ** remove_point(pointVal)\n\n**Return Type: ** None\n\n**Arguments (listed in the order in which they should be passed in): **\n\n1. pointVal (Type: Numeric): This argument is the value of the point you want to remove from the number line.\n\nWhen removing a point from the number line, you must use the remove_point() method and pass in the argument listed above. In order to remove a point from the number line, type the code shown below.\n```python\nnl.remove_point(1)\nnl.remove_point(2)\n```\nThe code above will remove points at 1 and 2 from the number line. If you try to remove a point from the number line that is not contained on the numberline, you will receive an error message.\n\n---\n##Adding a Range to the Number Line\n\n**Method to Use: ** add_range(lowerVal, includesLowerVal, upperVal, includesUpperVal)\n\n**Return Type: ** None\n\n**Arguments (listed in the order in which they should be passed in): **\n\n1. lowerVal (Type: Numeric): This argument is the value of the lower end of the range you want to add.\n2. inlcudesLowerVal: (Type: boolean): This argument is True if you want to include the value at the lower end of the range, and False otherwise.\n3. upperVal (Type: Numeric): This argument is the value of the upper end of the range you want to add.\n4. includesUpperVal (Type: Numeric): This argument is True if you want to include the value at the upper end of the range, and False otherwise.\n\nWhen adding a range to the number line, you must use the add_range() method and pass in the four arguments listed above in that order. In order to do this for a sample range (0,10], type the code shown below. \n```python\nnl.add_range(0,False,10,True)\n```\nThe code above will add the sample range (0,10] to the number line. If this range overlaps with another range, the number line will automatically merge the ranges that overlap. \n\n---\n##Removing a Range from the Number Line\n\n**Method to Use: ** remove_range(lowerVal, includesLowerVal, upperVal, includesUpperVal)\n\n**Return Type: ** None\n\n**Arguments (listed in the order in which they should be passed in): **\n\n1. lowerVal (Type: Numeric): This argument is the value of the lower end of the range you want to remove.\n2. inlcudesLowerVal: (Type: boolean): This argument is True if you want to include the value at the lower end of the range, and False otherwise.\n3. upperVal (Type: Numeric): This argument is the value of the upper end of the range you want to remove.\n4. includesUpperVal (Type: Numeric): This argument is True if you want to include the value at the upper end of the range, and False otherwise.\n\nWhen removing a range from the number line, you must use the remove_range() method and pass in the arguments listed above in that order. In order to remove a sample range of (0,5], type the code shown below.\n```python\nnl.remove_range(0,False,5,True)\n```\nThe code above will remove the sample range of (0,5] from the number line. If you try to remove a range that contains values that are not currently contained on the number line, you will receive an error message.\n\n---\n##Checking if the Number Line Contains a Point\n\n**Method to Use: ** contains_point(pointVal)\n\n**Return Type: ** boolean\n\n**Arguments (listed in the order in which they should be passed in): **\n\n1. pointVal (Type: Numeric): This argument is the value of the point you want to check whether the number line contains.\n\n\nWhen checking whether the number line currently contains a point, you must use the contains_point() method and pass in the argument listed above. In order to check if the number line contains the point 10, type the code shown below.\n```python\nnl.contains_point(10)\n```\nThe code above will return True if the number line contains the sample point 10, and False if it does not contain that point. \n\n---\n##Checking if the Number Line Completely Contains a Range \n\n**Method to Use: ** contains_range_totally(lowerVal, includesLowerVal, upperVal, includesUpperVal)\n\n**Return Type: ** boolean\n\n**Arguments (listed in the order in which they should be passed in): **\n\n1. lowerVal (Type: Numeric): This argument is the value of the lower end of the range you want to check whether the number line contains.\n2. inlcudesLowerVal: (Type: boolean): This argument is True if you want to include the value at the lower end of the range, and False otherwise.\n3. upperVal (Type: Numeric): This argument is the value of the upper end of the range you want to check whether the number line contains.\n4. includesUpperVal (Type: Numeric): This argument is True if you want to include the value at the upper end of the range, and False otherwise .\n\nWhen checking whether the number line currently completely contains a range, you must use the contains_range_totally() method and pass in the arguments listed above in that order. In order to do this for a sample range of (0,10), type the code shown below.\n```python\nnl.contains_range_totally(0,False,10,False)\n```\nThe code above will return True if the sample range (0,10) is completely contained in the number line, and False if it is not. \n\n---\n##Printing a Visual Representation of the Number Line\n\n**Method to Use: ** print_number_line()\n\n**Return Type: ** None\n\n**Arguments (listed in the order in which they should be passed in): ** None\n\nWhen printing a visual representation of the number line, you must use the print_number_line() method and pass in no arguments. In order to do this, type the code shown below. \n```python\nnl.print_number_line()\n```\nFor a number line that contains the points 1,2,3,4 and the ranges (0.5,0.6) and (4.5, 5.5], the code above will print the following to the command window.\n```python\n__(0.5,0.6)__[1,1]__[2,2]__[3,3]__[4,4]__(4.5,5.5]__\n```\n\n---\n\n\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://bitbucket.org/liammccluskey/number_line.git", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "number-line", "package_url": "https://pypi.org/project/number-line/", "platform": "", "project_url": "https://pypi.org/project/number-line/", "project_urls": { "Homepage": "https://bitbucket.org/liammccluskey/number_line.git" }, "release_url": "https://pypi.org/project/number-line/0.0.1/", "requires_dist": null, "requires_python": "", "summary": "Package for creating a number line that contains different ranges and points", "version": "0.0.1" }, "last_serial": 4043843, "releases": { "0.0.1": [ { "comment_text": "", "digests": { "md5": "cdbe822dce02ed79f60869964b5a1a80", "sha256": "6c0946ca0c20942d46a87fbd9adad189c801dc690348181e49e24f0817fe238b" }, "downloads": -1, "filename": "number_line-0.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "cdbe822dce02ed79f60869964b5a1a80", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 6913, "upload_time": "2018-07-09T14:39:46", "url": "https://files.pythonhosted.org/packages/a9/8a/b921c8d6059439c99163711597894ca17aacd6bc5408d0dfaa2191778e8c/number_line-0.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "684cd8841443ee2d243b4a7d83bff5d5", "sha256": "a15f30c6325501cbea55dba2b6bbb70d701c6b49647e46fd3a45f2be2e2b858a" }, "downloads": -1, "filename": "number_line-0.0.1.tar.gz", "has_sig": false, "md5_digest": "684cd8841443ee2d243b4a7d83bff5d5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4608, "upload_time": "2018-07-09T14:39:47", "url": "https://files.pythonhosted.org/packages/64/66/e2f8be315863e3c2d1b7f4250fa594f66ce0ea5a9c1afe8aaa7d2ef56273/number_line-0.0.1.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "cdbe822dce02ed79f60869964b5a1a80", "sha256": "6c0946ca0c20942d46a87fbd9adad189c801dc690348181e49e24f0817fe238b" }, "downloads": -1, "filename": "number_line-0.0.1-py3-none-any.whl", "has_sig": false, "md5_digest": "cdbe822dce02ed79f60869964b5a1a80", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": null, "size": 6913, "upload_time": "2018-07-09T14:39:46", "url": "https://files.pythonhosted.org/packages/a9/8a/b921c8d6059439c99163711597894ca17aacd6bc5408d0dfaa2191778e8c/number_line-0.0.1-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "684cd8841443ee2d243b4a7d83bff5d5", "sha256": "a15f30c6325501cbea55dba2b6bbb70d701c6b49647e46fd3a45f2be2e2b858a" }, "downloads": -1, "filename": "number_line-0.0.1.tar.gz", "has_sig": false, "md5_digest": "684cd8841443ee2d243b4a7d83bff5d5", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 4608, "upload_time": "2018-07-09T14:39:47", "url": "https://files.pythonhosted.org/packages/64/66/e2f8be315863e3c2d1b7f4250fa594f66ce0ea5a9c1afe8aaa7d2ef56273/number_line-0.0.1.tar.gz" } ] }