featureMatrix | R Documentation |
Compute a feature matrix (segmentation problems x features).
featureMatrix(data.sequences,
problem.vars, data.var)
data.sequences |
data.frame of sorted sequences of data to segment. |
problem.vars |
character vector of columns of |
data.var |
character vector of length 1 (column of |
Numeric feature matrix. Some entries may be missing or infinite; these columns should be removed before model training.
Toby Dylan Hocking <toby.hocking@r-project.org> [aut, cre]
test.df <- data.frame(
id=rep(1:2, each=10),
x=rnorm(20))
penaltyLearning::featureMatrix(test.df, "id", "x")
if(requireNamespace("neuroblastoma")){
data(neuroblastoma, package="neuroblastoma", envir=environment())
one <- subset(neuroblastoma$profiles, profile.id %in% c(1,2))
f.mat <- penaltyLearning::featureMatrix(
one, c("profile.id", "chromosome"), "logratio")
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.