inspect_RDS {lazy.tools}R Documentation

inspect the contents of RDS file

Description

This function inspects the contents of an RDS file.

Usage

inspect_RDS(RDname, func = str, max.level = 1, return = 0, ...)

Arguments

func

The function to apply to the contents of the .RDS file such as str or print,

max.level

the max.level option for str when func=str.

return

= 1 to return the the result of func.

...

additional parameters to func

RDS

The name of .RDS file

Details

Note that saveRDS(object,filename.RDS) saves a single object in an external file and that save(object1,object2,...,file="filename.RData") saves the multiple objects in an external file.

Examples

a <- 1;  b <- 2;  C <- matrix(1:6,3,2);  E <- letters[1:5]
ds <- data.frame(a,b,C);  ds2 <- list(C,ds)
Big <- list(a=a, b=b,C=C,E=E,ds=ds,ds2=ds2)
saveRDS(Big, file="testRDS.RDS")
inspect_RDS("testRDS.RDS")
inspect_RDS("testRDS.RDS", func=print)

# retrieve the contents from .RDS file
# loadRDS( RDSfilename )


[Package lazy.tools version 1.0.0.20260516 ]