Entering edit mode
5.6 years ago
i.am.filippov
•
0
I have MethyLumiSet object which has some NA
sumis.na(exprs(infdata)))
[1] 3822
Now how do I remove NA's from it and keep the same MethyLumiSet class for the result? I thought of something like:
exprs(infdata) <- exprs(infdata)[!is.na(exprs(infdata))]
but I'm not sure whether this is the correct way.
Isn't it the case that
infdata
is of classMethyLumiSet
whileexprs(infdata)
is not? You might be working with a 2D structure like a matrix or data.frame, which would make your life simpler.Yes you're right, I was wondering if there's a way to filter the
MethyLumiSet
itself without filtering just the m-values. I needMethyLumiSet
later on.Well, the MethyLumiSet seems to be a list of 2D data structures, so filtering the list doesn't make sense. You may need to create a copy of the list and then filter each 2D component of the new list.