Comments (4)
Sorry to hear about this error. Could you run the following code and send me the output generated?
outlier.sd <- 3
dat <- data.frame(
sample.name = sapply(qc.objects, function(x) x$sample.name),
methylated = sapply(qc.objects, function(x) x$median.m.signal),
unmethylated = sapply(qc.objects, function(x) x$median.u.signal),
stringsAsFactors=F
)
fit <- lm(methylated ~ unmethylated, dat)
dat$resids <- residuals(fit)
dat$methylated.lm <- predict(fit)
interval.size <- outlier.sd*sd(dat$resids)
dat$upper.lm <- dat$methylated.lm + interval.size
dat$lower.lm <- dat$methylated.lm - interval.size
dat$outliers <- (dat$resids > mean(dat$resids) + interval.size
| dat$resids < mean(dat$resids) - interval.size)
na.idx <- which(is.na(dat$outliers))
cat(nrow(dat), length(na.idx), "\n")
if (na.idx > 3) na.idx <- na.idx[1:3]
print(dat[na.idx,])
from meffil.
Hi,
thanks for your help.
Here is the output
`cat(nrow(dat), length(na.idx), "\n")
1 1
if (na.idx > 3) na.idx <- na.idx[1:3]
print(dat[na.idx,])
sample.name methylated unmethylated resids
206891110004_R01C01 206891110004_R01C01 2621.36 2521.409 0
methylated.lm upper.lm lower.lm outliers
206891110004_R01C01 2621.36 NA NA NA`
Thanks in advances,
Rossella
from meffil.
Ah I see. The qc.summary() is failing when it attempts to identify outliers because only one sample is being analysed. Although some quality information can be generated for a single sample, variation between samples is necessary to evaluate technical variation. Do you have more samples? Will you regularly need a QC procedure to apply to individual samples?
from meffil.
Thank you so much for your support. That was the issue.
To replay to your question no I will run QC onbatches of samples, and the tested with multiples samples worked perfectly. Thanks again
from meffil.
Related Issues (20)
- Length > 1 error on R 4.2 HOT 4
- Guidance on plink step in QC HOT 2
- ewas / champ output comparison HOT 1
- DMPs vs DMRs HOT 1
- Checks for sample swap detection HOT 1
- Creating chunks for parallelization using `meffil.normalize.samples()` error HOT 2
- meffil.ewas.summary with GDS HOT 2
- EPIC v2 multiple `IlmnID` per CpG `Name` behavior HOT 5
- meffil.normalize.samples function needs raw values HOT 2
- 450k, epicv1, and epicv2
- Normalization function creates many NAs HOT 4
- meffil.normalize.dataset() threw me an error HOT 4
- ewas.parameters <- meffil.ewas.parameters(sig.threshold=1e-20, max.plots=5)
- warning message from meffil.ewas.summary()
- qc.summary warning about scale guides HOT 1
- Issue in meffil:::guess.featureset HOT 5
- add new saliva reference
- usage of cell type output
- Issue with meffil.ewas model
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from meffil.