helper_search: Helper function for gtsearch

View source: R/gtsearch.R

helper_searchR Documentation

Helper function for gtsearch

Description

This is a helper function for gtsearch() to catch some errors and to mutate the Google series to our liking

Usage

helper_search(series, is_keyword, timeframe, as_tbl_ts = TRUE)

Arguments

series

A dataframe from gtrendsR::gtrends() with Google data.

is_keyword

A logical argument to determine, if we searched beforehand for a keyword (TRUE) or a category (FALSE).

timeframe

A time frame to search the queries in consisting of a start date and an end date in YYYY-MM-DD form.

as_tbl_ts

Logical value to determine if tibble should already be coerced to a tsibble with keyword or category column as key.


johannes97s/ifwtrends documentation built on Oct. 9, 2022, 7:01 p.m.