# Converte to coordenate in decimal
decimal = function(coord, num = TRUE, rad = TRUE)
{
out = sapply(coord,
function(coord, num, rad)
{
## standardized in vector numerical
crd = coord_clean(coord)
signal = sign(crd[1])
crd = abs(crd)
if(length(crd) == 1) if(rad) out = crd * (180/pi) else out = signal * crd
if(length(crd) == 2) if(rad) out = signal * (crd[1] + crd[2]/60) * (180/pi)
else out = signal * (crd[1] + crd[2]/60)
if(length(crd) == 3)
if(rad) out = signal * (crd[1] + crd[2]/60 + crd[3]/3600) * (180/pi) else
out = signal * (crd[1] + crd[2]/60 + crd[3]/3600)
if(!num) out = paste0(out, "\uB0")
return(out)
}, rad = rad, num = num #end function
)#end sapply
return(out)
}#end decimal
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.