This part is the description. It can be as long as you want but usually is one paragraph.

samplefunction(x, y = 10, z = c("yellow", "red", "green"))

Arguments

x

This is a required argument and has no default value.

y

Has a default value of 10.

z

Although this looks like it is a default string, the function match.arg() is used to set it in the function. With match.arg(), the string specifies what values are allowed and it will throw an error if not one of those. The default is the first value.

Value

A string with the values.

Examples

samplefunction(1)
#> [1] "1 10 yellow"