Search
 
SCRIPT & CODE EXAMPLE
 

PYTHON

how to reomve certain row from dataframe pandas

# delete 10th, 11th, and 15th row of df, axis = 0 signify rows, inplace=True means changes directly going to apply to df.
df.drop(labels=[10, 11, 15], axis=0, inplace=True)
# or
df = df.drop(labels=10, axis=0)

# don't forget to upvote :)
Comment

PREVIOUS NEXT
Code Example
Python :: pygame keys pressed 
Python :: ignition create dataset 
Python :: convert categorical column to int in pandas 
Python :: build url python 
Python :: debugar python 
Python :: colab kaggle dataset 
Python :: how to save array python 
Python :: python current utc offset 
Python :: set the root directory when starting jupyter notebooks 
Python :: rename columns in dataframe 
Python :: how to duplicate columns pandas 
Python :: add y axis label matplotlib 
Python :: print a random word from list python 
Python :: perfect number program in python 
Python :: cosine interpolation 
Python :: find nan value in dataframe python 
Python :: python strip newline from string 
Python :: python multi line print 
Python :: Python pandas drop any row 
Python :: install python3 6 ubuntu 20 
Python :: timed loop python 
Python :: python datetime to timestamp 
Python :: round godot 
Python :: how to print all rows in pandas 
Python :: countplot in pandas 
Python :: pygame.key.get_pressed() 
Python :: how to write a numpy array to a file in python 
Python :: get requests from python 
Python :: import load_iris 
Python :: python json load file 
ADD CONTENT
Topic
Content
Source link
Name
5+7 =