convert column in to a list code example
Example 1: python - convert a column in a dataframe into a list
myvar_list = df["myvar"].tolist()
Example 2: list of particular column in pandas dataframe
print(df.columns)
myvar_list = df["myvar"].tolist()
print(df.columns)