Distance between coordinates (all compared against each other - iterate?)

asfasf

New Member
Joined
Sep 20, 2018
Messages
15
Office Version
  1. 365
Platform
  1. Windows
Hi guys, I'm been reading and looking for a solution for this but I'm struggling, so I decided to ask for help.

Imagine I have a list of coordinates and I would like to have the distance in meters from each other.
Example:
coordinate1 - distance to coordinate2, coordinate3, coordinate_n
coordinate2 - distance to coordinate1, coordinate 3, coordinate_n
and so on.

Some form of iteration between them?

I found some threads about this, the closest one: Need to compare Latitude & Longitude coordinates to find closest office
Although it gives the distance in km, I need in meters, so I adapted and considered the radius in meters.

Is this possible? The goal is then to filter by a max distance in meters the user should choose and check which coordinates fall inside the radius.
Something like a heatmap.

I have attached a sample with 4 pairs of coordinates, but my main project has 10k pairs to check against each other.

Can you help me? Thank you very much

Column A = ID
Column B = Longitude
Column C = Latitude
 

Attachments

  • excel.png
    excel.png
    6.6 KB · Views: 45

Excel Facts

How to calculate loan payments in Excel?
Use the PMT function: =PMT(5%/12,60,-25000) is for a $25,000 loan, 5% annual interest, 60 month loan.
I put an Excel file in OneDrive for you to download to a desktop PC. It is a large file, and posting it here won't help. Anyway, it's the same formulas used in the link you cited.

I believe it does what you ask by reporting the distances between all locations to one another in a grid. Let us know if it helps.
 
Upvote 0
Solution
Thanks for sharing that file, really helpful :)
Although, Excel only supports 16k columns. What if I have 20k coordinates?
 
Upvote 0
Hi,​
as for huge data the smart way is any database software rather than Excel …​
 
Upvote 0
Thanks for sharing that file, really helpful :)
Although, Excel only supports 16k columns. What if I have 20k coordinates?
You're welcome.

Perhaps you can split it between two or more worksheets. There must be some logical division in your data, like N S E or W, Province, City, something.
 
Upvote 0
Access, WinDev, whatever as any database software with some coding language …​
 
Upvote 0

Forum statistics

Threads
1,223,893
Messages
6,175,248
Members
452,623
Latest member
cliftonhandyman

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top