Open onlyjsmith opened 5 years ago
It only works for 1 country. This line gets the country from the 1st coordinate. So if the points span 2 countries, it will only get layers for the country in which the first point lies.
Ah, right - that's what the [1]
does?
So will the bug then be that: points in two countries will only trigger download of data for 1 country, so we'd get nulls/NAs for points in 1 country?
Yes I think so. So far, accessing data across country-boundaries hasn't been a priority. Moving to icebox for the moment.
I've added something to the SPECS.md to explain this (commit 32a0b9744bb90a522eb64ab3d69e3f7babdc28a6). Might help us with debugging at some point!
This line looks like it can return more than 1 country if the points are across boundaries. Think this will cause bugs in most functions that use
country
, expecting it to be a single string.https://github.com/disarm-platform/fn-covariate-extractor/blob/cf35f608a1ad104675a96d34609c754cd532438a/fn-covariate-extractor/function/function.R#L109