-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
I am currently working with TCGA data with known batch effects within the methylation data, and was wondering if it would be possible/advisable from your perspective to add batch effect as part of the adjustment ? I would be very keen to see if there's any additional biological pathways emerging from your approach.
I would basically add batch as part of the clustering step:
model <- stepFlexmix(y2 ~ x + batch, k = 1:nmax, nrep = nrep, verbose = FALSE)
and subsequently also include it as part of the regression :
b_vs_pur <- lapply(1:nmax, function(z) {
if(z %in% cl) {
# Include all batch columns in the regression
lm(y[cl == z] ~ x[cl == z] + batch[cl == z, ]) # Use batch matrix as covariate
} else { NA }
})
b_vs_1mp <- lapply(1:nmax, function(z) {
if(z %in% cl) {
# Include all batch columns in the regression
lm(y[cl == z] ~ x2[cl == z] + batch[cl == z, ]) # Use batch matrix as covariate
} else { NA }
})
curious to hear your thoughts
Thank you
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels