R/myplot.R

Defines functions myplot

Documented in myplot

#' @title FUNCTION_TITLE
#' @description FUNCTION_DESCRIPTION
#' @param industry PARAM_DESCRIPTION
#' @param adf PARAM_DESCRIPTION
#' @return OUTPUT_DESCRIPTION
#' @details DETAILS
#' @examples 
#' \dontrun{
#' if(interactive()){
#'  #EXAMPLE1
#'  }
#' }
#' @rdname myplot
#' @export 
myplot <- function(industry, adf){
  plt <- ggplot(adf,aes(year,yearly_average_employment))+
    geom_line()+
    labs(title=paste0("yearly average employment for ",industry),
         caption="source: Real Time Remote Access (RTRA) data from the Labour Force Survey (LFS) by Statistics Canada."
    )+
    scale_y_continuous(labels=comma)
  return(fix_gg_labs(plt))
}
rpmartin/lmio documentation built on Jan. 3, 2022, 4:37 a.m.