Name | politicopolls JSON |
Version |
1.0.6
JSON |
| download |
home_page | |
Summary | Download polls data from Politico Polls. |
upload_time | 2023-01-09 09:51:24 |
maintainer | |
docs_url | None |
author | |
requires_python | >=3.9 |
license | MIT License Copyright (c) 2023 VRobert123 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. |
keywords |
politico
polls
download
scraper
scraping
election
polls
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Download polls from Politico Polls with this Python package.
Politico collects polls data from all european country, but doesn't give a possibility to download this data. If you want to use these polls data you can easy download that with this package in python. It's just some seconds.
There are some countries what is not available in the package, please consider upgrades in the future.
This package uses Python Selenium with Chrome driver. After the scraping of x and y axis, the package scraps every points's position, then with a simple linear regression, turn cx and cy values to dates and percentages.
Let me know if you have any observation.
# Usage
Import the package:
```
from politicopolls import politico
```
Assign a variable with the class in the module.
```
var = politico.Politico()
```
To get a list about available countries, type this:
```
var.get_list()
```
To download polls from a country, use this:
```
var.download('hungary')
```
If you want to work with the result dataframe, you can do this:
```
var.df
```
# Please notice
This is my first Python package, you can expect bugfixes and upgrades. The package uses Selenium and pandas so maybe a little bit slow. I am on it.
# License
MIT License
Raw data
{
"_id": null,
"home_page": "",
"name": "politicopolls",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.9",
"maintainer_email": "",
"keywords": "politico,polls,download,scraper,scraping,election,polls",
"author": "",
"author_email": "Robert Vamosi <vamosi.robert2@gmail.com>",
"download_url": "https://files.pythonhosted.org/packages/d5/a0/5226e4a6ff30bd287c349d125c79f1ada8fbec74cf2c522dda1489da1d69/politicopolls-1.0.6.tar.gz",
"platform": null,
"description": "# Download polls from Politico Polls with this Python package.\r\n Politico collects polls data from all european country, but doesn't give a possibility to download this data. If you want to use these polls data you can easy download that with this package in python. It's just some seconds. \r\n\r\nThere are some countries what is not available in the package, please consider upgrades in the future.\r\n\r\nThis package uses Python Selenium with Chrome driver. After the scraping of x and y axis, the package scraps every points's position, then with a simple linear regression, turn cx and cy values to dates and percentages. \r\n\r\nLet me know if you have any observation.\r\n\r\n# Usage\r\n\r\nImport the package:\r\n\r\n```\r\nfrom politicopolls import politico\r\n```\r\n\r\n\r\nAssign a variable with the class in the module.\r\n```\r\nvar = politico.Politico()\r\n```\r\n\r\nTo get a list about available countries, type this:\r\n```\r\nvar.get_list()\r\n```\r\n\r\nTo download polls from a country, use this:\r\n```\r\nvar.download('hungary')\r\n```\r\n\r\nIf you want to work with the result dataframe, you can do this:\r\n\r\n```\r\nvar.df\r\n```\r\n\r\n# Please notice\r\n\r\nThis is my first Python package, you can expect bugfixes and upgrades. The package uses Selenium and pandas so maybe a little bit slow. I am on it.\r\n\r\n# License\r\n\r\nMIT License\r\n",
"bugtrack_url": null,
"license": "MIT License Copyright (c) 2023 VRobert123 Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ",
"summary": "Download polls data from Politico Polls.",
"version": "1.0.6",
"split_keywords": [
"politico",
"polls",
"download",
"scraper",
"scraping",
"election",
"polls"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "57dd82eeebed4156e5a3af0a6549eb421667a7997ceaf552a54dcead71af2eb3",
"md5": "deac4b6cd54456e1d443d8584e400a2f",
"sha256": "4269add53681763b1f253c27a6919adf6da8a4af0cad00a9b62d95477e3627a6"
},
"downloads": -1,
"filename": "politicopolls-1.0.6-py3-none-any.whl",
"has_sig": false,
"md5_digest": "deac4b6cd54456e1d443d8584e400a2f",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.9",
"size": 5984,
"upload_time": "2023-01-09T09:51:22",
"upload_time_iso_8601": "2023-01-09T09:51:22.908582Z",
"url": "https://files.pythonhosted.org/packages/57/dd/82eeebed4156e5a3af0a6549eb421667a7997ceaf552a54dcead71af2eb3/politicopolls-1.0.6-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "d5a05226e4a6ff30bd287c349d125c79f1ada8fbec74cf2c522dda1489da1d69",
"md5": "91f5f56fb4cdf73f9d04af094c1c7e65",
"sha256": "d275aad590999b84057b96e8a96315f33ee73d2ba689f8b4a92caf69d93e43ad"
},
"downloads": -1,
"filename": "politicopolls-1.0.6.tar.gz",
"has_sig": false,
"md5_digest": "91f5f56fb4cdf73f9d04af094c1c7e65",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.9",
"size": 5227,
"upload_time": "2023-01-09T09:51:24",
"upload_time_iso_8601": "2023-01-09T09:51:24.651471Z",
"url": "https://files.pythonhosted.org/packages/d5/a0/5226e4a6ff30bd287c349d125c79f1ada8fbec74cf2c522dda1489da1d69/politicopolls-1.0.6.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-01-09 09:51:24",
"github": false,
"gitlab": false,
"bitbucket": false,
"lcname": "politicopolls"
}