Create an empty DataFrame in Pandas

By Poornima, 2 months ago
  • Bookmark
0

How to Create an empty DataFrame in Pandas?

Pandas
Dataframe
1 Answer
0

Empty DataFrame could be created with the help of pandas.DataFrame()

Syntax: pandas.Dataframe()
Return: Return a Dataframe object.


example

# import pandas library
import pandas as pd
  
# create an empty dataframe
my_df  = pd.DataFrame()
  
# show the dataframe
my_df

_

Your Answer

Webinars

More webinars

Related Discussions

Running random forest algorithm with one variable

View More