I have a list of postcodes (UK) in tableau that I use to generate a map of customers. I was trying to calculate the distances of postcodes from some particular places in the UK using the following formula:
3959 * ACOS
(
SIN(RADIANS(Lat)) * SIN(RADIANS(Lat2)) +
COS(RADIANS(Lat)) * COS(RADIANS(Lat2)) *
COS(RADIANS(Lon2) – RADIANS(Long))
)
my problem is: how do I get the longitude and latitude that tableau automatically generates in order to feed the formula above?
(refer to the formula: http://vizpainter.com/mapping-distances-an-alternative-approach/)