heigeo / climata

Python library for loading and iterating over climate and flow time series data (from ACIS/NOAA RCCs, CoCoRaHS, Hydromet/USBR, CNRFC ESP/NWS, SNOTEL/AWDB/NRCS, and NWIS/USGS)
http://climata.houstoneng.net
MIT License
83 stars 14 forks source link

climata.usgs.DailyValueIO paramID=00065 #17

Closed ssolson closed 5 years ago

ssolson commented 5 years ago

Hey, thank you for making this great tool.

I am using USGS site 15485500 ( https://waterdata.usgs.gov/nwis/uv/?site_no=15485500). Using the climata call inside a python script as:

from climata.usgs import DailyValueIO

data = DailyValueIO( start_date="2017-01-01", end_date="2018-01-01", station="15485500", parameter="00060", )

Everything works as expected.

However, if I want to return gage height (parameter="00065") the returned data instance only contains: "wq.io.exceptions.NoData: No data returned!"

I have tried this for multiple sites and the result is consistent across sites. I have tried to trace this issue through the climata package to the wq package but have had no success in finding the exact call sent to the USGS site. Can someone help me by pointing me to the exact call to the USGS site or pointing me to where I can correct this issue?

Thanks!

ssolson commented 5 years ago

It seems that the gage height is only available under the instant data. Therefore I must use the InstantValueIO and everything then works as expected.

from climata.usgs import InstantValueIO data = InstantValueIO( start_date="2017-01-01", end_date="2018-01-01", station="15485500", parameter="00065", )