Calculating Distance between two sets of geographic coordinates using only zip codes or cities

Calculating Distance between two sets of geographic coordinates using only zip codes or cities

EXCEL 4 UR PARENTS

54 года назад

3,724 Просмотров

This video used Excel data type Geography and Power Query to find the difference between 2 sets of coordinates. Using only zip codes, you can extract Lat and Long using Excel data types; these tables are then loaded into a power query to find the distance between points.

Power Query M Formula for Distance in Miles (Replace all the Bold with your column names):

Number.Acos(Number.Cos((90-[Latitude])*Number.PI/180)*Number.Cos((90-[Leads.Latitude])*Number.PI/180)
+ Number.Sin((90-[Latitude])*Number.PI/180)*Number.Sin((90-[Leads.Latitude])*Number.PI/180)*Number.Cos(([Longitude]-[Leads.Longitude])*Number.PI/180)) * 3959
Ссылки и html тэги не поддерживаются


Комментарии: