Description Usage Arguments Details Value Note Author(s) See Also Examples
writeToRepo
function writes an artifact to the local
or remote Repository. To learn more about artifacts
visit archivist2-package.
1 2 | writeToRepo(artifact, repo = NULL, archiveTags = TRUE, algo = "md5",
compress = "xz", compression_level = 9)
|
artifact |
An R object to be saved. For supported artifacts see details. |
repo |
A character denoting
an repository in which an artifact will be saved. If
set to |
archiveTags |
A
logical value denoting whether to archive tags from the
|
algo |
The algorithm to be used for
hashing. Will be passed to |
compress |
The type of compression, passed to save()
.
compression_level |
The level of compression, passed to
|
writeToRepo
function writes an artifact to the
local Repository (a directory) or remote Repository.
In local repository artifacts are saved with additional
properties like tags, which make them easier to find.
Every artifact is archived in a md5hash.rda
file.
For every artifact, md5hash
is a unique string
of length 32 that comes out as a result of
digest function, which uses a cryptographical MD5 hash
algorithm. A specific Tag
-relation is going to be
added to the backpack
dataset in case there is a
need to load the artifact with it's related data set - see
readFromRepo. Default settings may be changed by
using the archiveTag
argument with the FALSE
value. Tags
are artifact's attributes, different for
various artifact's classes. For more detailed information
check Tags Archived artifact can be searched in the
backpack
dataset by using the searchInRepo
functions. Artifacts can be searched by their Tags,
names
, classes
or archiving date
.
Supported artifact's classes are (so far):
lm
,
data.frame
,
ggplot
,
htest
,
trellis
,
twins
(result of agnes, diana or mona function)
,
partition (result of pam, clara or fanny fuction)
,
lda
,
qda
,
glmnet
,
survfit
.
To check what Tags
will be
extracted for various artifacts see Tags.
As a result of this function a character string is returned,
which determines the md5hash
of the artifact that was
used in the writeToRepo
function.
One can specify his own Tags
for artifacts by setting
artifact's attribute before call of the writeToRepo
function like this: attr(x, "tags" ) = c( "name1",
"name2" )
, where x
is artifact and name1,
name2
are Tags
specified by an user.
Przemyslaw Biecek, przemyslaw.biecek_at_gmail.com, Marcin Kosinski, m.p.kosinski_at_gmail.com
For more detailed information check the archivist2
package Use Cases. The list of supported
artifacts and their tags is available on wiki
on archivist2 Github
Repository. Other archivist2: createRepo
;
readFromRepo
; setRepo
1 2 3 4 5 | # objects preparation
## Not run:
# TODO: create examples or move from archivist
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.