Rates Limits in Geocoding [Open Street Map]




I'm working on a project where I have to do a georeferencing about 100k addresses. I used an open source (Open Street Map) to georeference them. However, after some research I realized that there is a limit of Requests. And in order to georeference around 1000 addresses, the program explodes ... In this situation, I used a Sys.sleep (0.5) function which is to do half a second interval between each address search. AND the program continues exploding...

Can someone help me find a function or line of code that allows the program to only make one address per second?

I hope someone can help me in this problem.
Thank you,


Looks like someone else had the same question re. the rate limit

I haven't used it personally, but there's a package, ratelimitr, that will let you set a rate limit on any R function:

From the README:

f <- function() NULL

# create a version of f that can only be called 10 times per second
f_lim <- limit_rate(f, rate(n = 10, period = 1))

# time without limiting
system.time(replicate(11, f()))
#>    user  system elapsed 
#>       0       0       0

# time with limiting
system.time(replicate(11, f_lim()))
#>    user  system elapsed 
#>    0.00    0.00    1.05


Thank you for your help mara!!


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.