powered by
Setting and resetting options is lengthy in command mode. WithOptions() allows to evaluate a function with temporary set options.
WithOptions()
WithOptions(optlist, expr)
a list with new option settings.
the expression to be evaluated
the function result
options, getOption
options
getOption
# NOT RUN { # original: print((1:10)^-1) # with new options WithOptions(list(digits=3), print((1:10)^-1)) # }
Run the code above in your browser using DataLab