-
Notifications
You must be signed in to change notification settings - Fork 60
Add SE and MAE support #351
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
@@ -39,17 +41,16 @@ Authors@R: | |||
person("Florian", "Rohart", role = "aut"), | |||
person("Ignacio", "Gonzalez", role = "aut"), | |||
person("Sebastien", "Dejean", role = "aut"), | |||
## key contributors |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comments are not supported, and they lead to an error
setMethod("mixOmics", signature = c(X = "matrix"), function( | ||
X, | ||
Y, | ||
indY, | ||
study, | ||
ncomp, | ||
keepX, | ||
keepY, | ||
design, | ||
tau = NULL, | ||
mode = c("regression", "canonical", "invariant", "classic"), | ||
scale, | ||
tol = 1e-06, | ||
max.iter = 100, | ||
near.zero.var = FALSE){ | ||
res <- internal_mixOmics( | ||
X, | ||
Y, | ||
indY, | ||
study, | ||
ncomp, | ||
keepX, | ||
keepY, | ||
design, | ||
tau = NULL, | ||
mode = c("regression", "canonical", "invariant", "classic"), | ||
scale, | ||
tol = 1e-06, | ||
max.iter = 100, | ||
near.zero.var = FALSE | ||
) | ||
return(res) | ||
} | ||
) | ||
|
||
#' @rdname mixOmics | ||
#' @export | ||
setMethod("mixOmics", signature = c(X = "list"), function( | ||
X, | ||
Y, | ||
indY, | ||
study, | ||
ncomp, | ||
keepX, | ||
keepY, | ||
design, | ||
tau = NULL, | ||
mode = c("regression", "canonical", "invariant", "classic"), | ||
scale, | ||
tol = 1e-06, | ||
max.iter = 100, | ||
near.zero.var = FALSE, | ||
...){ | ||
res <- internal_mixOmics( | ||
X, | ||
Y, | ||
indY, | ||
study, | ||
ncomp, | ||
keepX, | ||
keepY, | ||
design, | ||
tau = NULL, | ||
mode = c("regression", "canonical", "invariant", "classic"), | ||
scale, | ||
tol = 1e-06, | ||
max.iter = 100, | ||
near.zero.var = FALSE, | ||
... | ||
) | ||
return(res) | ||
} | ||
) | ||
|
||
internal_mixOmics <- function(X, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The old mixOmics function is converted into generic function. Otherwise I have not touched the existing code
Related to this issue: #347
This PR adds support for
SummarizedExperiment
andMultiAssayExperiment
classes. They are primary data containers in Bioconductor which is why I think that the support benefits both mixOmics and whole Bioconductor ecosystem.