check_function_layout {cleanr} | R Documentation |
Check a Function's Layout
Description
Run all function_checks
on a function.
Usage
check_function_layout(
object,
function_name = NULL,
max_lines_of_code = get_cleanr_options("max_lines_of_code"),
max_lines = get_cleanr_options("max_lines"),
max_num_arguments = get_cleanr_options("max_num_arguments"),
max_nesting_depth = get_cleanr_options("max_nesting_depth"),
max_line_width = get_cleanr_options("max_line_width"),
check_return = get_cleanr_options("check_return")
)
Arguments
object |
The function to be checked. |
function_name |
The name to be used for reporting. Stick with the
default: If NULL, it is taken from the |
max_lines_of_code |
|
max_lines |
See |
max_num_arguments |
See |
max_nesting_depth |
See |
max_line_width |
See |
check_return |
See |
Details
The functions catches the messages of "cleanr"-conditions
throw
n by function_checks
and, if it caught any,
throw
s them.
Value
Invisibly
TRUE
,
but see Details.
See Also
Other wrappers:
check_directory()
,
check_file_layout()
,
check_file()
,
check_functions_in_file()
,
check_package()
Examples
print(cleanr::check_function_layout(cleanr::check_num_lines))
[Package cleanr version 1.4.0 Index]