0

I need to serialise some Pandas DataFrame data for storing in the JSON. For this purpose I am converting float32 and float64 data types to native Python float.

  • Will there be implications for the data accuracy, or can Python float correctly prevent both of these Pandas data types?
  • Could there be other issues e.g. with NaN and Inf? (note: I am already aware that strict JSON does not handle Inf serialisation)
Mikko Ohtamaa
  • 82,057
  • 50
  • 264
  • 435
  • 2
    To that end, your float number will be a string, so you'll lose precision. https://stackoverflow.com/q/27098529/15239951 – Corralien Jun 08 '23 at 09:31

0 Answers0