0

I am attempting to add a large number of columns [0:100] at once to a DataFrame. (For now the values of the columns are NA). I know how to add or insert multiple at a time, through several methods such as the insert() method. But it still involves writing out each column name and attributes out. To do this for 100 columns would be tedious and not very clean. I was wondering if there was an easier way to make a series of columns [0:100] without writing each out one. Possibly through a loop?

Julie
  • 1
  • 1
  • [this might be useful](https://stackoverflow.com/questions/1704823/create-numpy-matrix-filled-with-nans) – bn_ln Oct 11 '22 at 04:13

0 Answers0