Answers for "make a dataframe with list of lists inside a list"

0

pandas create dataframe from list of lists

# Import pandas library
import pandas as pd
  
# initialize list of lists
data = [['tom', 10], ['nick', 15], ['juli', 14]]
  
# Create the pandas DataFrame
df = pd.DataFrame(data, columns = ['Name', 'Age'])
  
# print dataframe.
df
Posted by: Guest on April-27-2021

Code answers related to "make a dataframe with list of lists inside a list"

Code answers related to "TypeScript"

Browse Popular Code Answers by Language