downloadData | R Documentation |
These functions are downloading, reading, and attaching data sets described in the hdrm book.
To keep the size of the hdrm
package manageable, these data sets are not included with the package and must be downloaded separately using downloadData()
; this only needs to be done once.
downloadData(name)
readData(name)
attachData(name, envir = parent.frame())
name |
Name of data set to read/attach |
envir |
If attaching, to which environment? |
Data sets in hdrm are lists consisting of X
, y
, and possibly other elements.
readData
returns the list as an object that the user can name and use how they want.
attachData
assigns the elements of the list into the user's environment.
attachData
is often more convenient, but offers less control and potentially introduces side effects, such as overwriting an existing object X
if one already exists. See the examples for more details.
## Not run:
downloadData() # Download all data sets
downloadData(brca1) # Download a specific data set
## End(Not run)
Data <- readData(brca1)
dim(Data$X)
head(Data$y)
attachData(bcTCGA)
dim(X)
head(y)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.