BaşlayınÜcretsiz Başlayın

Generating mean frequency

We need to produce a metric which can be graphed over time. Our function check_word_in_tweet() returns a boolean Series. Remember that the boolean value True == 1, so we can produce a column for each keyword we're interested in and use it to understand its over time prevalence.

Bu egzersiz

Analyzing Social Media Data in Python

kursunun bir parçasıdır
Kursu Görüntüle

Egzersiz talimatları

  • Create a column called python and store the results of check_word_in_tweet() for the string '#python' in it.
  • Do the same, but with a column called rstats and the string '#rstats'.

Uygulamalı interaktif egzersiz

Bu örnek kodu tamamlayarak bu egzersizi bitirin.

# Create a python column
ds_tweets[____] = ____(____, ____)

# Create an rstats column
____[____] = ____(____, ____)
Kodu Düzenle ve Çalıştır