Skip to content

Instantly share code, notes, and snippets.

@csbailey5t
Created November 11, 2019 23:04
Show Gist options
  • Save csbailey5t/1fa7d2ecd14be347242dfaffae40c9fc to your computer and use it in GitHub Desktop.
Save csbailey5t/1fa7d2ecd14be347242dfaffae40c9fc to your computer and use it in GitHub Desktop.
Import a CoreLogic pipe delimited file and check for num of missing values in single col
import pandas as pd
# Read in delimited file, setting delimiter, and keeping only single col of interest
df = pd.read_table("StanfordUniversity_TAX_201906_IL.txt", delimiter="|", usecols=["YEAR BUILT"])
# Check unique values
df["YEAR BUILT"].unique()
# Count the number of null/NaN values
df["YEAR BUILT"].isnull().sum()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment