Closed Max-Bladen closed 1 year ago
The
if (any(sapply(cord.X, nrow) == 1)) {
cord.X <- cord.X[-which(sapply(cord.X, nrow) == 1)]
}
code now makes the following fail:
data(breast.TCGA)
X <- breast.TCGA$data.train$mirna
Y <- matrix(breast.TCGA$data.train$protein[,1], ncol=1)
rownames(Y) <- rownames(X)
pls.result <- pls(X, Y)
plotVar(pls.result, cex=c(3,4))
Erreur : cex must be either a vector of length 2 or a list of 2 vector components of length 184 and 1 respectively.
Addresses issue raised in this forum post.
Adjusted
get.name.and.value()
to ensure names of selected values are retained. Also added check inplotVar()
to remove the single Y feature fromcord.X
as this is unnecessary to plot. This is due to the single Y feature always having correlation of -1 or 1 with all components