Reads the head and tail of specified file and prints it the console and/or returns it as a character vector. This is called internally in several S3 methods described below.
Usage
check_file(.file, .head = 3, .tail = 5, .print = TRUE, .return = FALSE)
tail_output(.mod, ...)
# S3 method for class 'character'
tail_output(.mod, .head = 3, .tail = 5, .print = TRUE, .return = FALSE, ...)
# S3 method for class 'bbi_base_model'
tail_output(.mod, .head = 3, .tail = 5, .print = TRUE, .return = FALSE, ...)
tail_lst(.mod, ...)
# S3 method for class 'character'
tail_lst(.mod, .head = 3, .tail = 5, .print = TRUE, .return = FALSE, ...)
# S3 method for class 'bbi_base_model'
tail_lst(.mod, .head = 3, .tail = 5, .print = TRUE, .return = FALSE, ...)Arguments
- .file
Character scalar of path to file to read
- .head
Integer for number of lines to read from the top of the file
- .tail
Integer for number of lines to read from the bottom of the file
If
TRUE, the default, print resulting head and tail to console.- .return
If
FALSE, the default, returnsNULLinvisibly. IfTRUEreturns resulting head and tail as a character vector.- .mod
Model object or path associated with file.
- ...
arguments passed through to
check_file()
Functions
tail_output(character): Tail the OUTPUT file from a file path to a model.tail_output(bbi_base_model): Tail the OUTPUT file from abbi_base_modelobject.tail_lst(character): Tail the .lst file from a file path to a model.tail_lst(bbi_base_model): Tail the .lst file from abbi_base_modelobject.
