#' @title takes a string and converts to a tibble
#' @description separates a string by delimiters
#' @param my_string the string
#' @param delim the delimiters
#' @return tibble
#' @importFrom stringr str_split
#' @importFrom tibble tibble
#' @examples string2tibble("55,56&57",",|&")
#' @rdname string2tibble
#' @export
string2tibble <- function(my_string,delim){
naics <-str_split(my_string, delim)
my_df <- tibble(naics = as.numeric(unlist(naics)))
return(my_df)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.