Forum Discussion
weikiat98
Jun 10, 2023Copper Contributor
formula to convert degree minutes to degree decimals
Hello all, is there a better formula to convert degree minutes to degree decimals in excel? The formulas I currently use produce some inconsistencies coordinate points on my map. Refer to pictur...
SergeiBaklan
Jun 10, 2023Diamond Contributor
I'm not sure what are formats for latitude and longitude, but you may simplify your formula at least to
=IF( RIGHT(L2, 1) = "S", -1,
IF(RIGHT(L2, 1) = "N", 1, "")) *
(
LEFT(L2, FIND("-", L2) - 1) +
MID( L2, FIND("-", L2) + 1, LEN(L2) - FIND("-", L2) - 1 ) / 60
)
taking into account comparison in Excel is case insensitive by default and in arithmetic operations numbers as texts are automatically converted to numbers, e.g. = "1"+2 returns 3