def SciNoteToFloat(x): '''Takes a string writen in scientific notation and returns a float''' x = x.lower() x = x.partition("e") return (float(x[0])) * (int("1" + "0" * (-1 * int(x[2])))) mynum = "0.223E-7" print SciNoteToFloat(mynum)
print '%13.11f' % float('.0340344E-4') '0.00000340344'
Angemeldete Mitglieder können Beiträge verfassen, Updates folgen und mehr. Neu hier? Registriere ein kostenloses Konto.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.