0

Get column-index of a specific column-name e.g. Address should return 2 (you can assume the column exists and is unique). (Yes I know you shouldn't need to do this in general, this is only for debug while coding)

df = pd.DataFrame(np.random.rand(3,5), columns = ['Name','Age','Address','City','Zip'])

Related questions:

smci
  • 32,567
  • 20
  • 113
  • 146

0 Answers0