Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

Returns the first n rows

# Returns the first n rows

df.head()
# Row(age=2, name=u'Alicz')
df.head(1)
# [Row(age=2, name=u'Alice')]
Comment

Returns the first row as a Row

# Returns the first row as a Row

df.first()
# Row(age=2, name=u'Alice')
Comment

PREVIOUS NEXT
Code Example
Python :: anonymous function python 
Python :: nth catalan number 
Python :: lambda 
Python :: programação funcional python - lambda 
Python :: why is c++ faster than python 
Python :: pandas fillna multiple columns 
Python :: Sendgrid dynamic templating 
Python :: python count the vowels 
Python :: linkedlist python 
Python :: len dictionary python 
Python :: determinant of 3x3 numpy 
Python :: how to print 
Python :: how to implement dfa in python 
Python :: full_like numpy 
Python :: pivot table pandas 
Python :: .squeeze function in numpy 
Python :: getting current user in django 
Python :: python random numbers 
Python :: python class getters and setters 
Python :: how to define a dictionary in python 
Python :: python ravel function 
Python :: Python RegEx Subn – re.subn() Syntax 
Python :: how to set default file directory for jupyter notebook 
Python :: how to add new column in django 
Python :: download gzip file python 
Python :: python int to ascii string 
Python :: add Elements to Python list Using append() method 
Python :: or in if statement python 
Python :: tuplein python 
Python :: count function in python 
ADD CONTENT
Topic
Content
Source link
Name
1+4 =