select row in dataframe corresponding to another data frame

Hello,

I have two data frames: Total and TranscriptList.
Total:

*head(total)*
*               Name Length EffectiveLength       TPM NumReads   sample*
*1 ENST00000456328.2   1657        1440.925  0.059181    5.000 RNA21.77*
*2 ENST00000450305.2    632         416.425  0.000000    0.000 RNA21.77*
*3 ENST00000488147.1   1351        1134.925 41.682033 2773.726 RNA21.77*
*4 ENST00000619216.1     68           5.143  0.000000    0.000 RNA21.77*
*5 ENST00000473358.1    712         496.235  0.000000    0.000 RNA21.77*
*6 ENST00000469289.1    535         320.123  0.000000    0.000 RNA21.77*

Transcript list:

*head(transcript.list)*
*   ENST00000526025.2*
*1  ENST00000415148.6*
*2 ENST00000263398.11*
*3  ENST00000428726.8*
*4  ENST00000526669.6*
*5  ENST00000433892.6*
*6 ENST00000278386.10*

I want to select Total rows that contains a string (in name column) from TranscriptList. I have to do it with [ ] and %in%. I want to keep everything in the rows.

I did this command:

*total[, total$Name%in%transcript.list]* 

but it returns me that total has 0 columns...

Thank you for your help

This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.