Skip to content
Advertisement

How to add an empty column to a dataframe?

What’s the easiest way to add an empty column to a pandas DataFrame object? The best I’ve stumbled upon is something like

JavaScript

Is there a less perverse method?

Advertisement

Answer

If I understand correctly, assignment should fill:

JavaScript
User contributions licensed under: CC BY-SA
10 People found this is helpful
Advertisement