geco-bern / ingestr

Data ingest for points (given longitude, latitude, and required dates) from large global files or remote data servers and create time series at user-specified temporal resolution.
https://geco-bern.github.io/ingestr
42 stars 21 forks source link

Error for ingesting soil_wise data #49

Open yunkepeng opened 1 year ago

yunkepeng commented 1 year ago

Hi,

I just found in this line of code:

https://github.com/computationales/ingestr/blob/master/R/ingest_wise_byvar.R#L42

rename(ID = wise30sec_fin) should be changed to rename(ID = MU_GLOBAL)

When I use ingest(source="wise"..) to ingest soil wise data - it leads to bug - then when trying to solve it, I found here the variable was wrongly renamed. Because in this line the function aims to interpolate each site's unique number, and its variable name should be MU_GLOBAL (not wise30sec_fin). By correcting the code like above, the whole function works successfully.

Yunke