Skip to content

Instantly share code, notes, and snippets.

@lamorbidamacchina
Last active November 19, 2019 16:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lamorbidamacchina/532c3ffab8ada2e925d418f90cddb8f8 to your computer and use it in GitHub Desktop.
Save lamorbidamacchina/532c3ffab8ada2e925d418f90cddb8f8 to your computer and use it in GitHub Desktop.
if len(account_list) > 0:
for target in account_list:
item = api.get_user(target)
user_name = str(item.name)
screen_name = str(item.screen_name)
profile_image_url = str(item.profile_image_url)
description = str(item.description)
statuses_count = str(item.statuses_count)
friends_count = str(item.friends_count)
followers_count = str(item.followers_count)
tweets = str(item.statuses_count)
account_created_date = item.created_at
delta = datetime.utcnow() - account_created_date
account_age_days = delta.days
average_tweets = 0
if account_age_days > 0:
average_tweets = str(round(int(tweets)/int(account_age_days),2))
account_age_days = str(account_age_days)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment