You are here: Reference > Rule types > Data Set > Creating a Twitter data set record

Creating a Twitter data set record

You can create a Twitter data set record to track and analyze the text-based content that is posted on the Twitter social media site. By analyzing users' input, you can gain insight that helps you to structure the data in your application to deliver better services to customers and increase your customer base. For example, by tracking and analyzing tweets about your organization or your products, you can discover whether the customer response to the release of one of your product was positive or negative.

Use the Twitter data set to filter tweets according to the keywords that you specify. First, create a Twitter data set to connect with the Twitter API. Next, reference the data set from a data flow and use the Text Analyzer rule to analyze the text-based content of tweets.

Caution: Do not reference one instance of the Twitter data set in multiple data flows. Stopping one of such data flows, stops the Twitter data set in the other data flows.

Prerequisites:

Before you create a Twitter data set, complete the following tasks:

  1. In Designer Studio, click +Create > Data Model > Data Set.
  2. Enter the data set label and identifier.
  3. From the Type list, select Twitter.
  4. Specify the ruleset, Applies-to class, and ruleset version of the data set.

    Note: The Applies-to class for Twitter data sets must always be Data-Social-Twitter.

  5. Click Create and open.
  6. In the Retrieve tweets section, select the way in which your application retrieves tweets form the data set:
  7. On the Twitter tab, complete the Access details section with the OAuth settings from the Twitter application that you created:
  8. Optional: In the Access details section, enter the Klout score API key to see the metrics about the social influence of the Twitter users that you track.
  9. In the Keywords section, perform the following actions:
    1. Optional: Select the Search only in tweet text (ignore author handles and profile) check box to limit data retrieval to the text-based content of tweets.
    2. click Add keyword and enter the words that you want to find in the tweets.

      You can also enter the Twitter authors that you want to find in tweets (for example, @JohnSmith).

  10. In the Retrieve timeline section, click Add author and enter the names of users whose tweets you want to analyze.

    Note: As a best practice, complete either the Keywords or Timeline section for your application to filter the data effectively.

  11. Optional: In the Ignore section, click Add twitter handle, and enter the names of users whose posts you want to ignore.

    Note: See the Twitter REST API documentation for information about limitations when specifying keywords and authors.

  12. In the Search section, specify the retrieval settings for tweets:

    Note: The Search section appears only when you select the Playback option in the Retrieve tweets section.

  13. Optional: Click the Advanced options tab to configure additional options for filtering the data that is retrieved the Twitter data set.
  14. Click Save.