# Basic syntax: import pandas as pd empty_dataframe = pd.DataFrame() # Create empty dataframe with column names empty_dataframe = pd.DataFrame(columns=['your', 'column', 'names']) # Create empty dataframe with row names empty_dataframe = pd.DataFrame(index=['your', 'row', 'names'])
Here is what the above code is Doing:
1. Importing pandas as pd
2. Creating an empty dataframe with no column or row names
3. Creating an empty dataframe with column names
4. Creating an empty dataframe with row names