#' A function that changes the column names of a matrix by adding a suffix function unique does keep NA in the output
#' @description A function that changes the column names of a matrix by adding a suffix function unique does keep NA in the output
#' @param mat: matrix
#' @param suffix: character
#' @examplesÂ
#' givecolnames(ebfit$coef,'lgFCH')
#' givecolnames(ebfit$p,'p')
givecolnames<-function(mat,suffix){
if (length(grep('FCH',suffix))>0) {mat<-round(mat,2)}
colnames(mat)<-paste(suffix,colnames(mat),sep='_');
return(mat)}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.