#' Remove the file ext from fn
#' @param full_fn filename
#' @importFrom stringr str_remove
#' @export
remove_file_ext_from_fn <-
function(full_fn, rm_ext = TRUE, rm_path = TRUE) {
x <- full_fn
if (rm_ext == TRUE) {
x <- str_remove(full_fn, "[.]{1}[a-zA-Z]{1,6}$")
}
if (rm_path == TRUE) {
x <- basename(x)
}
return(x)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.