Skip to content
Christian Treffenstädt edited this page Jun 24, 2014 · 1 revision

Funktion zum formatieren von Nachkommastellen

format_num <- function(input, decimals){
  input <- round(input, decimals)
  output <- sprintf(paste("%.",decimals,"f", sep=''), input)
  return(output)
}