# -*- coding: utf-8 -*-
from setuptools import setup

packages = \
['algovis', 'algovis.searching', 'algovis.sorting']

package_data = \
{'': ['*'],
 'algovis.searching': ['_markdown_files/*'],
 'algovis.sorting': ['_markdown_files/*']}

install_requires = \
['matplotlib>=3.2.1,<4.0.0', 'rich>=3.3.1,<4.0.0']

setup_kwargs = {
    'name': 'algovis',
    'version': '0.1.6',
    'description': 'A Python library for visualising algorithms',
    'long_description': '[![CodeFactor](https://www.codefactor.io/repository/github/hotshot07/algovis/badge/master?s=197e9c6e50413744c0a2c43785a6dee096ee1a4d)](https://www.codefactor.io/repository/github/hotshot07/algovis/overview/master)  ![PyPI](https://img.shields.io/pypi/v/algovis) ![PyPI - Python Version](https://img.shields.io/pypi/pyversions/algovis) [![Downloads](https://pepy.tech/badge/algovis)](https://pepy.tech/project/algovis) <!-- ![PyPI - Downloads](https://img.shields.io/pypi/dm/algovis) --> ![GitHub last commit](https://img.shields.io/github/last-commit/hotshot07/algovis)  ![PyPI - License](https://img.shields.io/pypi/l/algovis) ![Netlify](https://img.shields.io/netlify/f4cede18-f2c6-4299-abc1-92b8a8ef9995) [![Made by](https://img.shields.io/badge/Made%20by-hotshot07-blue)](https://mackweb.in) [![Twitter Follow](https://img.shields.io/twitter/follow/gamesetmatch07?style=social)](https://twitter.com/elonmusk)\n\nAlgovis is a python library made for visualizing algorithms. Refer to the [documentation](https://algovisdocs.netlify.app/) for more info.\n\nCurrently the library has these algorithms\n\n#### Sorting\n\n- Bubble Sort\n- Insertion Sort\n- Selection Sort\n- Merge Sort\n- Quick Sort\n\n#### Searching\n\n- Linear Search\n- Binary Search\n\n\n## Getting Started\n\n### Prerequisites\n\nI would highly suggest making a virtual environment. The main purpose of a Python virtual environments is to create an isolated environment for Python projects. You can read more about them [here](https://realpython.com/python-virtual-environments-a-primer/).\n\n```bash\n# making a test folder\n\n$mkdir test_algovis\n\n# make it the current directory\n\n$cd test_algovis\n\n# making a virtual environment (you can replace envname with whatever name you like)\n\n$python3 -m venv envname\n\n# activating it\n\n$source envname/bin/activate\n```\n\nYou can only access algovis inside this virtual environment. To leave this virtual env when you\'re done trying out the library, type\n\n```bash\n$deactivate\n```\n\n### Installing\n\n```bash\n$pip3 install algovis\n```\n\n\n\n### Using the sorting package\n\n\n\n#### Visualize method\n\n```python\n# import the sorting package from library\nfrom algovis import sorting\n\n# importing random module to shuffle the list\nimport random\n\n# Making a list of 100 integers from 1-100\n# using list comprehension\nmy_list = [i+1 for i in range(100)]\n\n# shuffling the list\nrandom.shuffle(my_list)\n\n# making a BubbleSort class object by passing the shuffled list\nbs_object = sorting.BubbleSort(my_list)\n\n# calling the visualize method\nbs_object.visualize(interval= 100)\n```\n##### Output\n<img src="https://media.giphy.com/media/ieb13rrmvVWC02zmI8/giphy.gif" width="600">\n\n\n\n#### sort method\n\n```python\n# lets work on a shorter example now\nmy_list = [i + 1 for i in range(10)]\n\n# shuffling the list using random module\nrandom.shuffle(my_list)\n\n#making a quicksort object\nqs_object = sorting.QuickSort(my_list)\n\n#sorting in reverse with steps\nqs_object.sort(pivot = "first", steps = True, reverse = True)\n\n```\n\n#### evaluate method\n```python\n# calling the evaluate method and passing the optional parameter \'iterations\'\n# the list is sorted \'iterations\' number of times and the min, max and average time taken\n#to sort the list is returned in form of a formatted table\nbs_object.evaluate(iterations = 100)\n```\n\n\n#### info method\n```python\n# This method gives us information about the algorithm\nbs_object.info()\n```\n\n#### code method\n```python\n# It prints out the function for the algorithm\nbs_object.code()\n```\n\n>My terminal config is iTerm2 + ohmyzsh + powerlevel10k with dark backgroud. Colors may appear different in your terminal output. It\'s recommended to change the terminal color to something darker\n\n### Using the searching package\n\n>The searching package has the same methods as sorting, just instead of \'sort\' you have \'search\'\n>Refer to the [documentation](https://algovisdocs.netlify.app/) for more info\n\n#### search method\n```python\n#importing searching package\nfrom algovis import searching\n\n# making a list of integers from 1 to 100\n# using list comprehension\nmy_list = [i+1 for i in range(100)]\n\n#making binary search object\nbin_search = searching.BinarySearch(my_list)\n\n#calling the search method\nbin_search.search(42, steps = True)\n```\n\n#### visualize method\n\n```python\n# calling the visualize method\n# interval is the time between two different frames of the animation\nbin_search.visualize(42, interval = 1000)\n```\n<img src ="https://media.giphy.com/media/l3Cktj8ULcjHK3c90E/giphy.gif" width ="600">\n\n```python\n# or if you want to linear search 42\nlin_search = searching.LinearSearch(my_list)\n\n# setting a less interval to make a much faster animation\nlin_search.visualize(42, interval = 100)\n```\n\n### Doumentation\nThe documentation is built with [MKdocs](https://www.mkdocs.org/) using [material](https://squidfunk.github.io/mkdocs-material/) theme and is hosted on netlify. You can read it [here](https://algovisdocs.netlify.app/)\n\n### Author\n\n* **Mayank Arora** *(hotshot07)*\n\n\n### License\n\nThis project is licensed under the GNU Affero General Public License v3 (AGPL-3.0) - see the [LICENSE](LICENSE) file for details',
    'author': 'hotshot07',
    'author_email': 'aroram@tcd.ie',
    'maintainer': 'hotshot07',
    'maintainer_email': 'aroram@tcd.ie',
    'url': 'https://github.com/hotshot07/algovis',
    'packages': packages,
    'package_data': package_data,
    'install_requires': install_requires,
    'python_requires': '>=3.7.0,<4.0.0',
}


setup(**setup_kwargs)
