Skip to content

Commit

Permalink
minor updates related to v1.0.5
Browse files Browse the repository at this point in the history
  • Loading branch information
vasgat committed Sep 13, 2021
1 parent 6b7b8f2 commit adf0353
Show file tree
Hide file tree
Showing 5 changed files with 30 additions and 2 deletions.
6 changes: 6 additions & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

20 changes: 20 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,26 @@ wikirate4py makes it trivial to interact with WikiRate's API:
'Germany'
DataFrames
----------

The 1.0.5 version of wikirate4py library allows users to transform WikiRateEntity objects to DataFrames.
A usage example can be found below:

.. code-block:: python
from wikirate4py import API
api = API('your_api_token')
cursor = wikirate4py.Cursor(api.get_answers,
metric_name="Revenue EUR",
metric_designer="Clean Clothes Campaign",
year=2020)
answers = []
while cursor.has_next():
answers += cursor.next()
print(to_dataframe(answers).to_string())
Contributing
------------

Expand Down
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,4 @@ vcrpy==4.1.1
-e git+https://github.com/wikirate/wikirate4py.git@02de347d5ec0b02b88b912958fc2c7cf17af5efb#egg=wikirate4py
wrapt==1.12.1
yarl==1.6.3
pandas=1.3.3
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@
author='Vasiliki Gkatziaki',
author_email='[email protected]',
license='GPL-3.0',
download_url='https://github.com/wikirate/wikirate4py/archive/refs/tags/v1.0.4.tar.gz',
download_url='https://github.com/wikirate/wikirate4py/archive/refs/tags/v1.0.5.tar.gz',
packages=find_packages(exclude=["tests", "examples"]),
install_requires=[
"requests",
Expand Down
3 changes: 2 additions & 1 deletion wikirate4py/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"""
wikirate4py WikiRate API library
"""
__version__ = '1.0.4'
__version__ = '1.0.5'
__author__ = 'Vasiliki Gkatziaki'
__license__ = 'GPL-3.0'

Expand All @@ -19,3 +19,4 @@
from wikirate4py.models import (Company, CompanyItem, Topic, TopicItem, Metric, MetricItem, ResearchGroup,
ResearchGroupItem, Project, ProjectItem, CompanyGroup, CompanyGroupItem, Source,
SourceItem, Answer, AnswerItem, RelationshipAnswer, RelationshipAnswerItem, Region)
from wikirate4py.utils import to_dataframe

0 comments on commit adf0353

Please sign in to comment.