Module: Datarank::Client::Themes

Included in:
Datarank::Client
Defined in:
lib/datarank/themes.rb

Overview

Module containing methods for interacting with a topic’s themes

Instance Method Summary collapse

Instance Method Details

#themes(slug, options = {}) ⇒ Object

Return themes assigned to a topic

Parameters:

  • slug (String)

    A topic’s unique identifier slug



10
11
12
# File 'lib/datarank/themes.rb', line 10

def themes(slug, options={})
  get "/topics/#{slug}/themes", options
end

#themes_correlation(slug, options = {}) ⇒ Object

Return table for correlation between all themes on a topic

Parameters:

  • slug (String)

    A topic’s unique identifier slug



25
26
27
# File 'lib/datarank/themes.rb', line 25

def themes_correlation(slug, options={})
  get "/topics/#{slug}/themes/correlation", options
end

#themes_trend(slug, theme_id, options = {}) ⇒ Object

Return trend for a specific theme on a topic

Parameters:

  • slug (String)

    A topic’s unique identifier slug

  • theme_id (Integer)

    Unique ID of theme



18
19
20
# File 'lib/datarank/themes.rb', line 18

def themes_trend(slug, theme_id, options={})
  get "/topics/#{slug}/themes/trend/#{theme_id}", options
end