R : Copyright 2005, The R Foundation for Statistical Computing Version 2.1.1 (2005-06-20), ISBN 3-900051-07-0 R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details. R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications. Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for a HTML browser interface to help. Type 'q()' to quit R. > ### *
> ### > attach(NULL, name = "CheckExEnv") > assign(".CheckExEnv", as.environment(2), pos = length(search())) # base > ## add some hooks to label plot pages for base and grid graphics > setHook("plot.new", ".newplot.hook") > setHook("persp", ".newplot.hook") > setHook("grid.newpage", ".gridplot.hook") > > assign("cleanEx", + function(env = .GlobalEnv) { + rm(list = ls(envir = env, all.names = TRUE), envir = env) + RNGkind("default", "default") + set.seed(1) + options(warn = 1) + delayedAssign("T", stop("T used instead of TRUE"), + assign.env = .CheckExEnv) + delayedAssign("F", stop("F used instead of FALSE"), + assign.env = .CheckExEnv) + sch <- search() + newitems <- sch[! sch %in% .oldSearch] + for(item in rev(newitems)) + eval(substitute(detach(item), list(item=item))) + missitems <- .oldSearch[! .oldSearch %in% sch] + if(length(missitems)) + warning("items ", paste(missitems, collapse=", "), + " have been removed from the search path") + }, + env = .CheckExEnv) > assign("..nameEx", "__{must remake R-ex/*.R}__", env = .CheckExEnv) # for now > assign("ptime", proc.time(), env = .CheckExEnv) > grDevices::postscript("filehash-Examples.ps") > assign("par.postscript", graphics::par(no.readonly = TRUE), env = .CheckExEnv) > options(contrasts = c(unordered = "contr.treatment", ordered = "contr.poly")) > options(warn = 1) > library('filehash') Simple file-based hash table (version 0.2) > > assign(".oldSearch", search(), env = .CheckExEnv) > assign(".oldNS", loadedNamespaces(), env = .CheckExEnv) > cleanEx(); ..nameEx <- "db2env" > > ### * db2env > > flush(stderr()); flush(stdout()) > > ### Name: db2env > ### Title: Load database into environment > ### Aliases: db2env > ### Keywords: database > > ### ** Examples > > dbCreate("myDB") [1] TRUE > db <- dbInitialize("myDB") > dbInsert(db, "a", rnorm(100)) [1] TRUE > dbInsert(db, "b", 1:10) [1] TRUE > > env <- db2env(db) > ls(env) ## "a", "b" [1] "a" "b" > print(env$b) [1] 1 2 3 4 5 6 7 8 9 10 > mean(env$a) [1] 0.1088874 > > > > cleanEx(); ..nameEx <- "filehash-class" > > ### * filehash-class > > flush(stderr()); flush(stdout()) > > ### Name: filehash-class > ### Title: Class "filehash" > ### Aliases: filehash-class dbFetch dbInsert dbExists dbList dbDelete > ### dbReorganize dbDelete,filehash,character-method > ### dbExists,filehash,character-method dbFetch,filehash,character-method > ### dbInsert,filehash,character-method dbList,filehash-method > ### dbReorganize,filehash-method db2env,filehash-method > ### Keywords: classes > > ### ** Examples > > dbCreate("myDB") ## Create files 'myDB.idx' and 'myDB.rdb' Warning in dbCreate("myDB") : overwriting existing file 'myDB.idx' with index file Warning in dbCreate("myDB") : overwriting existing file 'myDB.rdb' with data file [1] TRUE > db <- dbInitialize("myDB") > dbInsert(db, "a", 1:10) [1] TRUE > dbInsert(db, "b", rnorm(1000)) [1] TRUE > dbExists(db, "b") ## 'TRUE' [1] TRUE > > dbList(db) ## c("a", "b") [1] "a" "b" > dbDelete(db, "a") [1] TRUE > dbList(db) ## "a" [1] "b" > > > > cleanEx(); ..nameEx <- "filehash-package" > > ### * filehash-package > > flush(stderr()); flush(stdout()) > > ### Name: filehash-package > ### Title: filehash overview > ### Aliases: filehash-package filehash > ### Keywords: database > > ### ** Examples > > ## See 'class ? filehash' for examples > > > > ### *