aeolus.util.
fmt_lonlat
Convert longitude or latitude value to string with a hemisphere identifier.
value (int) – Value of longitude or latitude. Note that this function is only for integer values.
lon_or_lat (str) – Longitude or latitude
degree (bool, optional) – If true, a TeX degree symbol is included
str
Examples
>>> fmt_lonlat(-25, "lon") '25W' >>> fmt_lonlat(89, "lat", degree=True) '89$^\\degree$N' >>> fmt_lonlat(0, "lon") '0'