Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Submission: pyntrinio (Python) #30

Open
10 of 22 tasks
Zhang-Haipeng opened this issue Mar 17, 2020 · 3 comments
Open
10 of 22 tasks

Submission: pyntrinio (Python) #30

Zhang-Haipeng opened this issue Mar 17, 2020 · 3 comments
Assignees

Comments

@Zhang-Haipeng
Copy link

Zhang-Haipeng commented Mar 17, 2020


name: pyntrinio
about: Python package for retrieving data from Intrinio API objects
title: pyntrinio
labels: 1/editor-checks, New Submission!
assignees: Braden Tam @bradentam , Mike Chen @miketianchen


Submitting Author: Roc Zhang (@Zhang-Haipeng ), Samantha Solomon (@slbsolomon), Aakanksha Dimri (@aakanksha023 ), Sirine Chahma (@sirine-chahma)
Package Name: pyntrinio
One-Line Description of Package: Python package for retrieving data from Intrinio API objects
t
Repository Link: here
Version submitted: v1.1.0
Editor: Varada Kolhatkar (@kvarada)
Reviewer 1: Braden Tam @bradentam
Reviewer 2: Mike Chen @miketianchen
Archive: TBD
Version accepted: TBD


Description

  • Include a brief paragraph describing what your package does:

Accessing "historical stock data", or "financial statement data" requires massive volumes of stock data and involves several discretions. Intrinio provides access to clean financial data with an API platform that can easily be used to extract data and perform further analysis on it. But the problem persists that the data can not be directly analysed from Intrinio objects. That is where pytrinio comes in. This package will offer a variety of functions that allow users to seamlessly transform Intrinio objects into either python dictionaries or a pandas dataframe. This will enable users to make the most of Intrinio's reliable and easy-to-use API platform, as well as the analysis capabilities that are available in python's environment.

Scope

  • Please indicate which category or categories this package falls under:
    • Data retrieval
    • Data extraction
    • Data munging
    • Data deposition
    • Reproducibility
    • Geospatial
    • Education
    • Data visualization*

* Please fill out a pre-submission inquiry before submitting a data visualization package. For more info, see this section of our guidebook.

  • Explain how the and why the package falls under these categories (briefly, 1-2 sentences):

This package is for retrieving data from the Intrinio API objects and covert it into known and easy to understand python object types like dictionary or dataframe.

  • Who is the target audience and what are scientific applications of this package?

Anyone using Intrinio API for accessing financial statements and stock prices would find this package useful.

  • Are there other Python packages that accomplish the same thing? If so, how does yours differ?

No such package exists yet.

  • If you made a pre-submission enquiry, please paste the link to the corresponding issue, forum post, or other discussion, or @tag the editor you contacted:

Technical checks

For details about the pyOpenSci packaging requirements, see our packaging guide. Confirm each of the following by checking the box. This package:

  • does not violate the Terms of Service of any service it interacts with.
  • has an OSI approved license
  • contains a README with instructions for installing the development version.
  • includes documentation with examples for all functions.
  • contains a vignette with examples of its essential functions and uses.
  • has a test suite.
  • has continuous integration, such as Travis CI, AppVeyor, CircleCI, and/or others.

Publication options

JOSS Checks
  • The package has an obvious research application according to JOSS's definition in their submission requirements. Be aware that completing the pyOpenSci review process does not guarantee acceptance to JOSS. Be sure to read their submission requirements (linked above) if you are interested in submitting to JOSS.
  • The package is not a "minor utility" as defined by JOSS's submission requirements: "Minor ‘utility’ packages, including ‘thin’ API clients, are not acceptable." pyOpenSci welcomes these packages under "Data Retrieval", but JOSS has slightly different criteria.
  • The package contains a paper.md matching JOSS's requirements with a high-level description in the package root or in inst/.
  • The package is deposited in a long-term repository with the DOI:

Note: Do not submit your package separately to JOSS

Are you OK with Reviewers Submitting Issues and/or pull requests to your Repo Directly?

This option will allow reviewers to open smaller issues that can then be linked to PR's rather than submitting a more dense text based review. It will also allow you to demonstrate addressing the issue via PR links.

  • Yes I am OK with reviewers submitting requested changes as issues to my repo. Reviewers will then link to the issues in their submitted review.

Code of conduct

P.S. Have feedback/comments about our review process? Leave a comment here

Editor and Review Templates

Editor and review templates can be found here

@bradentam
Copy link

bradentam commented Mar 18, 2020

Package Review

Please check off boxes as applicable, and elaborate in comments below. Your review is not limited to these topics, as described in the reviewer guide

  • As the reviewer I confirm that there are no conflicts of interest for me to review this work (If you are unsure whether you are in conflict, please speak to your editor before starting your review).

Documentation

The package includes all the following forms of documentation:

  • A statement of need clearly stating problems the software is designed to solve and its target audience in README
  • Installation instructions: for the development version of package and any non-standard dependencies in README
  • Vignette(s) demonstrating major functionality that runs successfully locally

Readthedocs does not seem to contain the functions

  • Function Documentation: for all user-facing functions

Perhaps have the function descriptions in the readme in a table with description, input, output to make it more readable
Docstring description should explicitly mention the arguments

  • Examples for all user-facing functions
  • Community guidelines including contribution guidelines in the README or CONTRIBUTING.
  • Metadata including author(s), author e-mail(s), a url, and any other relevant metadata e.g., in a setup.py file or elsewhere.

Readme requirements
The package meets the readme requirements below:

  • Package has a README.md file in the root directory.

The README should include, from top to bottom:

  • The package name
  • Badges for continuous integration and test coverage, the badge for pyOpenSci peer-review once it has started (see below), a repostatus.org badge, and any other badges. If the README has many more badges, you might want to consider using a table for badges, see this example, that one and that one. Such a table should be more wide than high.
  • Short description of goals of package, with descriptive links to all vignettes (rendered, i.e. readable, cf the documentation website section) unless the package is small and there’s only one vignette repeating the README.

A small typo I picked up on: pytrinio instead of pyntrinio.

  • Installation instructions

It might have been more clear if you also listed you have to install intrinio-sdk first

  • Any additional setup required (authentication tokens, etc)
  • Brief demonstration usage

No mention of how to import
Example could be a bit more comprehensive by including output
You can specify python in the markdown to make the example code look nicer and more readable

  • Direction to more detailed documentation (e.g. your documentation files or website).
  • If applicable, how the package compares to other similar packages and/or how it relates to other packages
  • Citation information

Functionality

  • Installation: Installation succeeds as documented.
  • Functionality: Any functional claims of the software been confirmed.
  • Performance: Any performance claims of the software been confirmed.
  • Automated tests: Tests cover essential functions of the package and a reasonable range of inputs and conditions. All tests pass on the local machine.

The functions should be in separate .py files so that you can see the coverage per function.
In the coverage add poetry install as a second step otherwise it won’t run

  • Continuous Integration: Has continuous integration, such as Travis CI, AppVeyor, CircleCI, and/or others.
  • Packaging guidelines: The package conforms to the pyOpenSci packaging guidelines.

Final approval (post-review)

  • The author has responded to my review and made changes to my satisfaction. I recommend approving this package.

Estimated hours spent reviewing: 3 hours


Review Comments

Pyntrinio is a very niche package and seems to have a lot of functionality. For the most part, it is well documented and not too difficult to get started. There were a few roadblocks on the way but they are not major. Specifically, there is no mention in the readme on how to import the functions and how to properly call the functions.

Although this is fairly minor, instead of importing via from pyntrinio import pyntrinio, you can have separate .py files for each function and in the init.py file have from pyntrinio.pyntrinio import function for each function and then the user will simply have to type import pyntrinio. Having separate .py files will also allow deeper inspection of branch coverage and an easier collaborative workflow. In terms of usability/readability, the function names are a bit too verbose and it would be good to rename the keys/column names of the gather_financial_statement_time_series and gather_financial_statement_company_compare function outputs.

Overall, I think this package has a lot of potential to become a very useful tool for bridging the gap between APIs and python usable objects.

@miketianchen
Copy link

miketianchen commented Mar 20, 2020

Package Review

Please check off boxes as applicable, and elaborate in comments below. Your review is not limited to these topics, as described in the reviewer guide

  • As the reviewer I confirm that there are no conflicts of interest for me to review this work (If you are unsure whether you are in conflict, please speak to your editor before starting your review).

Documentation

The package includes all the following forms of documentation:

  • A statement of need clearly stating problems the software is designed to solve and its target audience in README
  • Installation instructions: for the development version of package and any non-standard dependencies in README
  • Vignette(s) demonstrating major functionality that runs successfully locally
  • Function Documentation: for all user-facing functions
  • Examples for all user-facing functions
  • Community guidelines including contribution guidelines in the README or CONTRIBUTING.
  • Metadata including author(s), author e-mail(s), a url, and any other relevant metadata e.g., in a setup.py file or elsewhere.

Readme requirements
The package meets the readme requirements below:

  • Package has a README.md file in the root directory.

The README should include, from top to bottom:

  • The package name
  • Badges for continuous integration and test coverage, the badge for pyOpenSci peer-review once it has started (see below), a repostatus.org badge, and any other badges. If the README has many more badges, you might want to consider using a table for badges, see this example, that one and that one. Such a table should be more wide than high.
  • Short description of goals of package, with descriptive links to all vignettes (rendered, i.e. readable, cf the documentation website section) unless the package is small and there’s only one vignette repeating the README.
  • Installation instructions
  • Any additional setup required (authentication tokens, etc)
  • Brief demonstration usage
  • Direction to more detailed documentation (e.g. your documentation files or website).
  • If applicable, how the package compares to other similar packages and/or how it relates to other packages
  • Citation information

Functionality

  • Installation: Installation succeeds as documented.
  • Functionality: Any functional claims of the software been confirmed.
  • Performance: Any performance claims of the software been confirmed.
  • Automated tests: Tests cover essential functions of the package and a reasonable range of inputs and conditions. All tests pass on the local machine.
  • Continuous Integration: Has continuous integration, such as Travis CI, AppVeyor, CircleCI, and/or others.
  • Packaging guidelines: The package conforms to the pyOpenSci packaging guidelines.

Final approval (post-review)

  • The author has responded to my review and made changes to my satisfaction. I recommend approving this package.

Estimated hours spent reviewing: 2 hours


Review Comments

Good job! Pyntrinio is a unique idea, and I can see how it can improve workflow related to stock-related tasks/projects. I thought the Readme was very coherent and easy to follow. However, I think you guys are missing an instruction to tell the user to run pip install intrinio_sdk before downloading Pyntrinio. I was stuck on this and couldn't install pyntrinio at first because of this. In addition, perhaps leave some instruction on how to import the functions in the examples section of the readme.

  • One very small problem I found with gather_financial_statement_company_compare is that if I entered a ticker not covered in the sandbox data for the US Fundamentals and Stock Prices data feed (ex. 'GOOG') such as gather_financial_statement_company_compare(api_key,['AAPL', 'GOOG'], 'income_statement', '2019', 'Q1'). The error message I got is "Invalid agruments: please make sure that your statement/year/period are valid". I think the error message should point out an invalid ticker is entered, so users don't spend time checking whether their statement/year/period are valid.
  • gather_stock_time_series function has the same very minor issue as well. gather_stock_time_series gives 'Invalid API Key: please input a valid API key as a string' when I wanna check Google stocks. This same issue applies for gather_financial_statement_time_series as well.
  • gather_stock_returns crashes when I run something like gather_stock_returns(api_key, ['AAPL', 'GOOG'], "2017-12-31", "2019-03-01")

Another small thing that came up is the example in the pyntrinio.py file for gather_financial_statement_time_series doesn't work, but the example for it in the Readme does work.

Sorry, it's so well done, I could only nitpick minor issues! Great work overall!

@aakanksha023
Copy link

aakanksha023 commented Mar 26, 2020

Hey! Braden (@bradentam ) and Mike (@miketianchen).
Thank you for taking out the time to review our work. We appreciate the feedback and have addressed the concerns here and here.

Hope It is up to your expectations given the time constraint. If there are some issues, which have not been addressed or are still not clear. Please feel free to comment further.

We are proud to release a latest version 1.2.0 of pyntrinio

Yours sincerely,
@aakanksha023
@slbsolomon
@sirine-chahma
@Zhang-Haipeng

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants