strr_multi | R Documentation |
strr_multi
takes a daily table and a host table and identifies which
listings in the daily table are multilistings on each date.
strr_multi(
daily,
host,
thresholds = c(EH = 2L, PR = 3L, SR = NA, HR = NA),
combine_listing_type = TRUE,
combine_housing = TRUE,
field_name = multi,
quiet = FALSE
)
daily |
A data frame of daily STR activity in standard UPGo format. |
host |
A data frame of STR host activity in standard UPGo format. |
thresholds |
An integer vector indicating the thresholds to establish multilisting status for each listing type. If the vector is unnamed, the options will be read in the order "Entire home/apt", "Private room", "Shared room", "Hotel room". If the vector is named, using the full listing type names ("Entire home/apt", "Private room", "Shared room", "Hotel room") or acronyms ("EH", "PR", "SR", "HR"), the values can be presented in any order. An NA or 0 value means that multilisting calculations will not be performed for that listing type. |
combine_listing_type |
A logical scalar. Should multilisting status for one listing type (e.g. "Entire home/apt") confer multilisting status on the other listing types operated by a host on a given day, regardless of whether the other listing types exceeded the multilisting threshold (default)? |
combine_housing |
A logical scalar. Should housing and non-housing listings be combined for the purposes of establishing multilisting status (default)? |
field_name |
A symbol or character string to name the new logical field identifying multilisting status in the output table. The default is 'multi'. |
quiet |
A logical scalar. Should the function execute quietly, or should it return status updates throughout the function (default)? |
The function summarizes the listings operated by a given host on a given date to determine if the listings are "multilistings"–i.e. more listings operated by a single host than is consistent with the host being a home sharer.
The output will be the 'daily' input table with one additional logical field (with name taken from the 'field_name' argument) indicating multilisting status.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.