#' Get dairy products name as vector
#'
#' @param df name of the data frame, default is dairy_plant
#'
#' @return a vector
#' @export
#'
#' @examples
#' get_product_names_vector(df = dairy_plant)
#' get_product_names_vector()
get_product_names_vector <- function(df = dairy_plant) {
unique(df$product_type)
}
#' Get company names
#'
#' @param df name of the data frame, default is dairy_plant
#'
#' @return a nx1 tibble
#' @export
#'
#' @examples
#' get_company_names(df = dairy_plant)
#' get_company_names()
get_company_names <- function(df = dairy_plant){
unique(df$company_name)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.