Applying multiple filter criteria to a pandas DataFrame

In this section, we will learn about methods for applying multiple filter criteria to a pandas DataFrame. We will use logical AND/OR conditional operators to select records from our real dataset. We'll also see how to use the isin() method for filtering records. We will demonstrate the isin method on our real dataset for both single column and multiple column filtering.

We will start by importing the pandas module and reading the dataset of house prices from zillow.com into the Jupyter Notebook, as follows:

data = pd.read_table('data-zillow.csv', sep=',')
data.head()

The following is the output:

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.218.63.38