Question: Do a subset of s4 object based on ensembl gene biotype?
0
gravatar for mdahl3105
3 months ago by
mdahl31050
mdahl31050 wrote:

Hi all

I am quite new to R, but using the DESeq2 package for analyzing total RNA-seq. data.

I would like to do a heatmap of only a subset of the differentially expressed genes, i.e. only protein-coding genes.

Thus, how can I inpute information on gene_biotype into the S4 object (results of DESeq2) or directly into the dds?

The only solution I have found involve converting res to a dataframe and merging with a dataframe containing the info on gene_biotype, but as this does not subset the s4 object data I am pretty stuck.

I would very much appreciate any suggestions as intensive google-ing and reading up on various posts over many days have not yet brought me closer to a solution.

deseq2 • 70 views
ADD COMMENTlink modified 3 months ago • written 3 months ago by mdahl31050
Answer: Do a subset of s4 object based on ensembl gene biotype?
0
gravatar for Michael Love
3 months ago by
Michael Love24k
United States
Michael Love24k wrote:

If you can get a list of the gene IDs, gene.ids from a table that has the biotype information, you can subset a DESeqDataSet like so:

dds.sub <- dds[gene.ids,]
ADD COMMENTlink written 3 months ago by Michael Love24k
Answer: Do a subset of s4 object based on ensembl gene biotype?
0
gravatar for mdahl3105
3 months ago by
mdahl31050
mdahl31050 wrote:

I can't believe the solution was so simple, but definitely had a rewarding detour the last days which helped me understand all elements of DESeq2 much better.

Thanks for the hint. :)

ADD COMMENTlink written 3 months ago by mdahl31050
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 400 users visited in the last hour