Can someone help me out? I'm trying to use Distributive Flow Lines Tool for Human Movement Analysis, but unfortunately I keep on getting this Error Message: Traceback(most recent call last); File “<string>”, line 136, in updateParameters ValueError: invalid literal for float(): 1009529,06119841. Can someone help me out? Does ArcGis provide any other tool for that purpose?
Solved! Go to Solution.
The problem is to do with using a comma separator.
>>> myString = '10000,02837' >>> float(myString) # it doesn't work Runtime error Traceback (most recent call last): File "<string>", line 1, in <module> ValueError: invalid literal for float(): 10000,02837 >>> myString = '10000.02837' >>> float(myString) 10000.02837 # it works!
Try changing all the commas in that field to periods.
Since that is not a part of the esri suite of extensions...perhaps you could elaborate as to where this might be obtained... but based on 1009529,06119841 could you post the code if you have it...if it is in python
The problem is to do with using a comma separator.
>>> myString = '10000,02837' >>> float(myString) # it doesn't work Runtime error Traceback (most recent call last): File "<string>", line 1, in <module> ValueError: invalid literal for float(): 10000,02837 >>> myString = '10000.02837' >>> float(myString) 10000.02837 # it works!
Try changing all the commas in that field to periods.
Darren may be on to something... try to see your regional settings and look for the 'decimal_point' separator option. In this example, you will see that a period is used in Canada
>>> import locale >>> loc = locale.getlocale() >>> loc (None, None) >>> locale.localeconv() {'mon_thousands_sep': '', 'mon_grouping': [], 'decimal_point': '.', 'p_sep_by_space': 127, 'int_curr_symbol': '', 'n_cs_precedes': 127, 'positive_sign': '', 'p_sign_posn': 127, 'n_sep_by_space': 127, 'p_cs_precedes': 127, 'thousands_sep': '', 'negative_sign': '', 'frac_digits': 127, 'n_sign_posn': 127, 'currency_symbol': '', 'mon_decimal_point': '', 'int_frac_digits': 127, 'grouping': []}
>>>
Dan and Darren, thanks for your suggestions. I need to talk to our administrator before changing the local settings, right? I downloaded this program from: Distributive Flow Maps – More Raster, More Faster | Applications Prototype Lab.
That is absolutely Perfect. It worked like Magic. Thanks, once again, Dan and Darren!
Hi Baffour Awuah I unmarked your own post as the correct answer. Could you mark the thread that answered your question as the correct one?