how to extract only two columns from dataframe in python code example Example: python: select specific columns in a data frame df = df[["Column_Name1", "Column_Name2"]]