Home > other >  Numpy into a CSV file data type errors
Numpy into a CSV file data type errors

Time:09-22

When writing the CSV file to form displayed after the decimal point, in the form of print but there is no change,
This is the code
 
B=np. Arange (60). Reshape (3, 20)
Np. Savetxt (' biggest sv, b, FMT='%. 2 f, delimiter=', ')
Print (b)


This is the result of I run:


This is the result of want to output:


Hope god can inform, thank!

CodePudding user response:

Tried % d, %. 18 e works, is % f is not working
  • Related