#' Prepend a sample ID to a maximum intensity tibble
#'
#' @param tib An intensity tibble generated by
#' penepma_get_max_total_intensity_z or
#' penepma_get_max_primary_intensity_z.
#'
#' @param sample_id String. A unique sample identifer
#'
#' @return a tibble. The sample_ID will be the first column
#' followed by Symbol, IZ, S0, S1, Int.mu, Int.se, Int.snr
#'
#' @import dplyr
#'
#' @export
#'
prepend_sample_id_max_int_tib <- function(tib, sample_id){
nr <- nrow(tib)
sample_id <- rep(sample_id, nr)
rv <- tibble::add_column(tib, Sample.ID=sample_id) %>%
# reorder columns
select(Sample.ID, Symbol, IZ, S0, S1, Int.mu, Int.se, Int.snr)
return(rv)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.