build_era5_land_request

53 views
Skip to first unread message

Julia Smith

unread,
Sep 17, 2025, 4:56:15 PM9/17/25
to NicheMapR
I am using the mcera5 package and I want to request era5 data and then put it into micro_era5(). This works. However, I want to get better spatial resolution by using era5-land where possible (it doesn't have all the variables needed but it has some and I can use coarser data from era5 for the variables era5-land doesn't have). I am trying to use mcera5's build_era5_land_request() function to get this data, but even when I make the request quite small it says my API request is too large. Any advice? I may turn to python or another package. If by any change anyone has a workflow in which they do what I'm trying to do (combine era5 and era5-land data into one .nc file in the right format to feed to micro_era5), that would be amazing!

Thank you!

P.S.
I am attaching some code which returns:
Downloading ERA5 data for 2019 (months 6)... [1] -105.41 [1] -105.39 [1] 39.99 [1] 40.01 [1] "2019-06-01 MDT" [1] "2019-06-01 23:00:00 MDT" Your request will all be queried at once and does not need to be combined. Requesting data to the cds service with username c0537df0-bfc1-47f0-b7e5-c3bbdfd1357b Error downloading data for 2019: permission deniedcost limits exceeded403Your request is too large, please reduce your selection.https://cds.climate.copernicus.eu/api/retrieve/v1/processes/reanalysis-era5-land/executef57d218f-b1a7-4c90-9257-a4beeaf00e3b Error: Original file C:\Users\jmsmi\Downloads\eralandRexample\era_data\nc_files/eraCO2019_2019_6.nc not found NULL
era5landattempt.R

NicheMapR

unread,
Sep 17, 2025, 5:01:36 PM9/17/25
to NicheMapR
Hi Julia,
Dave Klinges who has been working on this I think so hopefully he'll have an answer.
All the best,
Mike

David Klinges

unread,
Sep 18, 2025, 4:13:46 PM9/18/25
to NicheMapR
Hi Julia,

Annoying, the API limits on ECMWF, especially for ERA5-land, are fairly low, given how much traffic they receive. So it's not an R vs Python issue as much as the API itself, regardless of whether you submit the query via R or Python. The same limits apply when you download data manually via the website requests (eg here for ERA5-land).

With that said, there's two steps you can take that incorporate recent updates that might help:

re-install the ecmwfr R package from GitHub, to incorporate recent changes that Koen Hufkens made there: 
remotes::install_github("bluegreen-labs/ecmwfr")

re-install mcera5 R package from GitHub, which incorporates some recent changes that I made to build_era5_land_request() to help rectify this: 
remotes::install_github("dklinges9/mcera5")

You still will only be able to download about a month or so at a time for a fairly small extent. I haven't yet had the opportunity to incorporate using the native GRIB format instead of netCDF, which will increase the limit a bit more. Hoping to address that in the coming months.

Best,
Dave

--
You received this message because you are subscribed to the Google Groups "NicheMapR" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nichemapr+...@googlegroups.com.
To view this discussion, visit https://groups.google.com/d/msgid/nichemapr/f44d2841-6ed4-45ce-b1ee-1bf85742c647n%40googlegroups.com.


--
David Klinges, PhD
Assistant Professor, Rutgers University (incoming)
Reply all
Reply to author
Forward
0 new messages