Long listing of R session objects
Usage
lldf(
n = Inf,
envir = -1L,
items = NULL,
use_utils_objectsize = TRUE,
all.names = TRUE,
...
)Arguments
- n
integerorInfindicating how many objects to include in the outputdata.frame.- envir
environmentwhere the list of objects is obtained, default-1Lsearches the environment of the caller, usually the user workspace. Other recognized options:characterstring suitable foras.environment()which recognizes the search path returned bysearch()integerornumericequivalent to environment relative position as used inls()argumentpos.
- items
characterof items to include, default NULL.- use_utils_objectsize
logical, default TRUE, whether to preferutils::object.size(), otherwise it will attempt to usepryr::object_size()if the package is installed.- all.names
logicalpassed tobase::ls()indicating whether to include all names, whereall.names=TRUEwill include hidden objects whose name begin with"."such as".First".- ...
additional arguments are passed to
ls(), notablypatterncan be passed to subset objects by regular expression.
Details
This function expands base::ls() by also determining the
object size, and sorting to display the top n objects by
size, largest first.
This package will call pryr::object_size if available,
otherwise falls back to utils::object.size().
See also
Other jam practical functions:
breakDensity(),
call_fn_ellipsis(),
checkLightMode(),
check_pkg_installed(),
colNum2excelName(),
color_dither(),
exp2signed(),
getAxisLabel(),
isFALSEV(),
isTRUEV(),
jargs(),
kable_coloring(),
log2signed(),
middle(),
minorLogTicks(),
newestFile(),
printDebug(),
reload_rmarkdown_cache(),
renameColumn(),
rmInfinite(),
rmNA(),
rmNAs(),
rmNULL(),
setPrompt()
Examples
lldf(10);
#> $size
#> character(0)
#>
# custom environment
newenv <- new.env();
newenv$A <- 1:10;
newenv$df <- data.frame(A=1:10, B=11:20);
lldf(envir=newenv);
#> name class bytes size
#> df df data.frame 944 944 bytes
#> A A integer 96 96 bytes
rm(newenv);