Skip to content
This repository has been archived by the owner on Jun 2, 2023. It is now read-only.

nhd observation file columns names #70

Open
janetrbarclay opened this issue May 19, 2023 · 2 comments
Open

nhd observation file columns names #70

janetrbarclay opened this issue May 19, 2023 · 2 comments

Comments

@janetrbarclay
Copy link
Collaborator

In the zarr file of nhd resolution observations drb_temp_observations_nhdv2.zarr the time column should be renamed to date (the temporal coordinate is already date)

@lekoenig
Copy link
Collaborator

Below is a preview of the data frame that gets saved to a zarr store in drb_temp_observations_nhdv2.zarr. In this data frame, multiple observations for a given site-day have been aggregated to 1 value per site-day. If multiple observations were aggregated, time == NA, otherwise, we retain the time value, although I notice here that the formatting of the time stamps was not retained and so this column is an integer. Depending on how we're using the time column, we may want to address that.

I don't think I'm entirely following your initial request. I cannot rename time to date there is already a column named date which we use to chunk the data when building the zarr. I'm wondering - do you use the time column somehow, or could we simply omit it?

head(p2a_drb_temp_obs_by_comid)
#>  A tibble: 6 x 10
#>  Rowwise: 
#>     COMID date       site_id                                     source  time mean_temp_c min_temp_c max_temp_c sd_mean_temp_c flag 
#>     <int> <date>     <chr>                                       <chr>  <dbl>       <dbl>      <dbl>      <dbl>          <dbl> <chr>
#> 1 1748535 2001-07-10 USGS-01413070, USGS-01413088, USGS-01413092 wqp       NA        16.6       15.1       19.7            2.7 ""   
#> 2 1748535 2001-08-07 USGS-01413070, USGS-01413088, USGS-01413092 wqp       NA        19         17.5       20.5            1.5 ""   
#> 3 1748535 2006-10-10 USGS-01413088                               wqp    43200        12.7       12.7       12.7           NA   ""   
#> 4 1748535 2006-10-17 USGS-01413088                               wqp    42300         8          8          8             NA   ""   
#> 5 1748535 2006-11-01 USGS-01413088                               wqp    39600         9.4        9.4        9.4           NA   ""   
#> 6 1748535 2006-11-15 USGS-01413088                               wqp    41400         9.8        9.8        9.8           NA   ""

@janetrbarclay
Copy link
Collaborator Author

Let me get back to you on this. I was getting and error before and it seemed like it was connected to the time column, but now I'm not sure why.

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

No branches or pull requests

2 participants