Display the Argument List of a Function

DESCRIPTION:
Displays the argument names and their default expressions for a function.

USAGE:
args(x)

REQUIRED ARGUMENTS:
x:
the name of a function. A character string is also accepted, and is useful when the function name would not be interpreted as a name by the parser.

VALUE:
a copy of x with the body replaced by NULL. Printing this will reveal the names and default expressions of the arguments. Using args offers no advantage over looking at the entire function itself, except in the case of functions with very long bodies.

NOTE:
In previous releases, args operated by printing the USAGE section of the helpfile for the function.

SEE ALSO:
help .

EXAMPLES:
args(persp)

# Returns the following: function(x, y, z, xlab = "X", ylab = "Y", zlab = "Z", axes = T, box = T, eye = NULL, zlim, ar = 1, ...) NULL

c # short function; don't need args()

function(..., recursive = F) amp;.Internal(list(..., recursive), "S_unlist", T, 1)

args("[") # need a character string here

function(x, ..., drop = T) NULL

f2 <- args(f) ; fix(f2) # duplicate argument list of f, edit new body