Answer by alistaire for geosphere distHaversine() & dplyr - error wrong...
You need to operate rowwise, so distHaversine is passed a single set of pairs at once instead of all the rows:runways %>% rowwise() %>% mutate(CTD = distHaversine(c(LON, LAT), c(LON2, LAT2)))##...
View Articlegeosphere distHaversine() & dplyr - error wrong length for vector, should be 2
I am unable to resolve the error: "wrong length for vector, should be 2" when trying to calculate the (runway length) distance between two points (runway thresholds / ends).To make things worse, I fail...
View Article