#' Loads sequence files
#'
#' Loads sequence files
#'
#' @param file_name The full or relative path and name of the file
#' @param file_type The type of file. Default: FASTA
#' @export
read_seq <- function(file_name, file_type = 'FASTA'){
if (tolower(file_type) == 'fasta'){
dat <- seqinr::read.fasta(file_name)
dat <- sapply(dat, paste, collapse = '')
} else {
stop(paste('File type ', file_type, ' not supported.', sep = ''))
}
return(dat)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.