I am writing function that involve other function from base R with alot of arguments. For example (real function is much longer):
myfunction <- function (data
Try three dots instead of four, and add the ellipsis argument to the top level function:
myfunction <- function (dataframe, Colv = NA, ...) { matrix <- as.matrix (dataframe) out <- heatmap(matrix, Colv = Colv, ...) return(out) }