import pandas as pd
# Represents big data 6-10 gig dataframes
main_df = pd.DataFrame([
['10-10-2018','i like apple'],
['10-10-2018','bananas are my favorite fruit'],
['10-10-2018','kiwi and apple shakes are the best'],
['10-10-2018','got some rotten fruit']
],columns=['date','text'])
# Sanity check for read in
print(main_df.head())
# Keywords I am interested in sorting by
keywords =['apple','banana','kiwi']
def sort_by_keyword(keyword):
# list to hold indexes of matches
sortedIndex = []