Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

how do we create a dataframe in python

# Import pandas library 
import pandas as pd 
  
# initialize list of lists 
data = [['Group A', 85], ['Group B', 92], ['Group C', 88]] 
  
# Create the pandas DataFrame 
df = pd.DataFrame(data, columns = ['Name', 'Score']) 
  
# print dataframe. 
df 
Source by datatofish.com #
 
PREVIOUS NEXT
Tagged: #create #dataframe #python
ADD COMMENT
Topic
Name
6+9 =