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

discharge monthly statistics #63

Closed
yueyin1992 opened this issue Feb 2, 2020 · 4 comments
Closed

discharge monthly statistics #63

yueyin1992 opened this issue Feb 2, 2020 · 4 comments

Comments

@yueyin1992
Copy link

Hi,
I am wondering if the monthly statistics data can also be downloaded through the function? Thanks!

Krystal

@mroberge
Copy link
Owner

mroberge commented Feb 7, 2020

Hi Krystal,
This is a great idea! I haven't implemented this yet, but it should be easy to do. I already have a system for reading tab-delimited files in my current Develop branch, and I've added a few USGS services that deliver information this way. The stats service would be relatively simple to query.

@mroberge
Copy link
Owner

Hi Krystal, @yueyin1992

Thank you for the suggestion!

I just added (5292a1a) a new USGS stats service that can report on daily, monthly, or annual discharge statistics. It works like this:
hf.stats('01541200', 'monthly')
and it will return a dataframe with information from the USGS.

I am considering a different format however. I may want to return an object that stores the header AND the data.

@yueyin1992
Copy link
Author

Thanks so much! I tried to reinstall the hydrofunctions package but it returned "AttributeError: module 'hydrofunctions' has no attribute 'stats'". I am new to Python. Could you let me know what might be the problems? Thanks.

@mroberge
Copy link
Owner

mroberge commented Mar 5, 2020

Hi yueyin1992!
I haven't merged my changes into the main branch yet. I generally wait until I do a release for that. Right now I am getting ready to do a release in the next week or two. In the meantime, you can do this:

pip install git+https://github.com/mroberge/hydrofunctions.git@develop --upgrade

This will install hydrofunctions from github instead of PyPI, and it will use my 'develop' branch instead of the current Master branch.

I've made some changes to how hydrofunctions works, so please let me know if you have any problems!
-Marty

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

2 participants