njtierney / maxcovr

Tools in R to make it easier to solve the Maximal Coverage Location Problem
http://maxcovr.njtierney.com/
GNU General Public License v3.0
43 stars 12 forks source link

vectorize the spherical_distance_cpp #11

Closed njtierney closed 6 years ago

njtierney commented 8 years ago

Basically, change it so each input is a NumericVector, then loop spherical_distance for 1:length(lat1) ...etc.

njtierney commented 7 years ago

This would also mean that we would remove maxcovr::spherical_distance, replacing it with the c++ function, which would be at least twice as fast.

njtierney commented 6 years ago

This will not be relevant anymore once geodist is used, I don't think