filter factor DGEList
1
0
Entering edit mode
dojo89 • 0
@dojo89-24417
Last seen 3.5 years ago

Hello together,

I am new in the R universe and working with RNAseq data from three different cell lines. For analysis I am using edgeR. Now, I have two batches of data. I plotted them all together in a MDS plot. If I compare the controls in each batch per cell line I found a lot of differential expressed genes for one cell lines. To get a better idea of what is going on I would like to create a MDS plot exclusively with this cell line while ignoring the other two. For that I was wondering if I could to some kind of filtering of the DGEList-object. My sample names are factors in "y_keep[["samples"]][["group"]]" But because it is a factor all my trials to sort them were unsuccessful....

Could you help me with this? Thanks :)

edger • 658 views
ADD COMMENT
1
Entering edit mode
@gordon-smyth
Last seen 28 minutes ago
WEHI, Melbourne, Australia

Just subset the DGEList by column, for example something like

plotMDS( y[,CellLine==1] )
ADD COMMENT
0
Entering edit mode

Thanks for the fast response :) I have already tried it and received this error massage:

> plotMDS(y_keep[,samples=="HCC4006"])
Fehler in h(simpleError(msg, call)) : 
  Fehler bei der Auswertung des Argumentes 'j' bei der Methodenauswahl für Funktion '[': Objekt 'samples' nicht gefunden

Any further idea?

Thanks a lot!

ADD REPLY
0
Entering edit mode

Well, you don't have an object called samples in your session so naturally you get an error. You haven't shown us what is in your data object but I am guessing that you need:

j <- y_keep$samples$group=="HCC4006"
plotMDS(y_keep[,j])

You will need to get some familiarity with base R in order to use edgeR comfortably. We assume that people are familiar enough with base R to be able to use the "$" operator. So y_keep$samples is a data.frame contained in y_keep and group is a factor contained in y_keep$samples.

I suggest you do a bit of exploring, for example:

names(y_keep)
names(y_keep$samples)
head(y_keep$samples)
table(y_keep$samples$group)
ADD REPLY

Login before adding your answer.

Traffic: 985 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6