| data.iloc[0] # first row of data frame (Aleshia Tomkiewicz) - Note a Series data type output. | ||||||||||
| data.iloc[1] # second row of data frame (Evan Zigomalas) | ||||||||||
| data.iloc[-1] # last row of data frame (Mi Richan) | ||||||||||
| # Columns: | ||||||||||
| data.iloc[:,0] # first column of data frame (first_name) | ||||||||||
| data.iloc[:,1] # second column of data frame (last_name) | ||||||||||
data.iloc[:,-1] # last column of data frame (id)
Multiple columns and rows can be selected together using the .iloc indexer.
|
embedded system,Arduino,Raspberry pi,ARM7,MM32,STM32,PIC and Python,Django,Datascience and web development
Wednesday, February 2, 2022
how to use pandas iloc
Subscribe to:
Post Comments (Atom)
-
using python we can create our on DB using python in mysql. please follow the below lines of code import pymysql #create the database conne...
-
0885-8993 (c) 2015 IEEE. Personal use is permitted, but republication/redistribution requires IEEE permission. See http://www.ieee.org/pub...
No comments:
Post a Comment