I am trying to run this command in R in order to run a function:
xlsxToR <- function(\"C:\\\\Users\\\\Nabila\\\\Dropbox\\\\IsolutionsProject\\\\ServiceReques
Functions in R
When you are using function
in R you are defining a function (You can use ?function
to see the documentation). Inside the parentheses after function
you set the arguments of the function. You can also set default values for those arguments using =
. After that the body of the function should follow, i.e. an R expression containing the code of the function.
Your case
This line of code does not run a function. It defines a function with name xlsxToR
. The first thing in the parenthesis is a string, not an argument name, which causes the error. Also your function is just a definition of some argumnents without a body, which probably is not what you are trying to do.