Advertisement
Guest User

Untitled

a guest
Mar 27th, 2017
49
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.37 KB | None | 0 0
  1. def load_tweets(tweet_file):
  2.  
  3. """ Load and process a Twitter analytics data file """
  4.  
  5. # Read tweet data (obtained from Twitter Analytics)
  6. tweet_df = pd.read_csv(tweet_file)
  7.  
  8. # Drop irrelevant columns
  9. tweet_df = tweet_df.drop(tweet_df.columns[[13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39]], axis=1)
  10.  
  11. return tweet_df
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement