input: Write a function to visually summarize the Twitter data. The function should take in a list of dictionaries, where each dictionary represents a tweet with fields like 'author', 'date', 'text', 'likes', and 'retweets'. The function should generate three plots: one summarizing the number of tweets by author, one summarizing the number of likes per tweet, and one summarizing the number of retweets per tweet.
  
  def summarize_twitter_data(tweets):
      import matplotlib.pyplot as plt
      
      authors = [tweet['author'] for tweet in tweets]
      num_tweets = [authors.count(author) for author in set(authors)]
      plt.xlabel('Tweet Authors')
      plt.ylabel('Number of tweets')
      plt.title('Tweet Author Summary')
      plt.bar(set(authors), num_tweets)
      plt.show()
  
      num_likes = [tweet['likes'] for tweet in tweets]
      plt.xlabel('Tweets')
      plt.ylabel('Number of Likes')
      plt.title('Number of Likes Summary')
      plt.bar(range(len(tweets)), num_likes)
      plt.show()
  
      num_retweets = [tweet['retweets'] for tweet in tweets]
      plt.xlabel('Tweets')
      plt.ylabel('Number of Retweets')
      plt.title('Number of Retweets Summary')
      plt.bar(range(len(tweets)), num_retweets)
      plt.show()
  
  assert summarize_twitter_data([{'author': 'user1', 'date': '2023-01-01', 'text': 'Hello', 'likes': 10, 'retweets': 5}, {'author': 'user2', 'date': '2023-01-02', 'text': 'Hi', 'likes': 20, 'retweets': 10}, {'author': 'user1', 'date': '2023-01-03', 'text': 'Hey', 'likes': 15, 'retweets': 7}])==None
  assert summarize_twitter_data([])==None
output: def summarize_twitter_data(tweets):
      import matplotlib.pyplot as plt
      
      if not tweets:
          return
      
      authors = [tweet['author'] for tweet in tweets]
      num_tweets = [authors.count(author) for author in set(authors)]
      plt.figure(1)
      plt.xlabel('Tweet Authors')
      plt.ylabel('Number of tweets')
      plt.title('Tweet Author Summary')
      plt.bar(set(authors), num_tweets)
      plt.show()
  
      num_likes = [tweet['likes'] for tweet in tweets]
      plt.figure(2)
      plt.xlabel('Tweets')
      plt.ylabel('Number of Likes')
      plt.title('Number of Likes Summary')
      plt.bar(range(len(tweets)), num_likes)
      plt.show()
  
      num_retweets = [tweet['retweets'] for tweet in tweets]
      plt.figure(3)
      plt.xlabel('Tweets')
      plt.ylabel('Number of Retweets')
      plt.title('Number of Retweets Summary')
      plt.bar(range(len(tweets)), num_retweets)
      plt.show()