'how can i arrange to_txt file rightside with 12 spaces in Pandas

I have a table in Pandas and I want to change it to text file like below enter image description here

When i code mf.to_csv("mf191.txt", sep=' ',float_format = '%.3f', index=False, header=False) text file is like below i want to change text file arranged to rightside with 12 spaces How can i do?? enter image description here



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source