Entering edit mode
9.9 years ago
tiago211287
★
1.5k
Hello Guys, I need a little help from those who know R a lot. I am still learning and despite trying alone I still get stuck in some task. For example, I have these 2 files separated by tab. And I need to compare the ensembl id's s so I can get How many Up-regulated genes X Down-regulated genes I have per chromosome and also per band. Can someone help me? I think this should be quite easy but still....to hard for a beginner like me.
File1.txt
Group1 Band Chromosome Name Group2 Band Chromosome Name Group3 Band Chromosome Name
ENSMUSG00000004707 H3 1 ENSMUSG00000005763 H2.3 1 ENSMUSG00000098895 H2.1 1
ENSMUSG00000006403 H3 2 ENSMUSG00000008136 B 2 ENSMUSG00000046814 E4 2
ENSMUSG00000008475 G3 3 ENSMUSG00000025917 A2 3 ENSMUSG00000004707 H3 3
ENSMUSG00000009772 E4 4 ENSMUSG00000025938 A3 4 ENSMUSG00000004552 H3 4
File2.txt
Group1 Expression Group2 Expression Group3 Expression
ENSMUSG00000004707 Up ENSMUSG00000025938 Up ENSMUSG00000004552 Up
ENSMUSG00000006403 Up ENSMUSG00000025917 Up ENSMUSG00000004707 Up
ENSMUSG00000008475 Down ENSMUSG00000005763 Down ENSMUSG00000046814 Down
ENSMUSG00000009772 Down ENSMUSG00000008136 Down ENSMUSG00000098895 Down
Did not help much
You might wanna Google individual parts of my answer. Giving you the entire solution is easy, but not helpful in the long term.
I still need some help here, I am trying alone has been a while and am tired
Think of it this way: You have a tab separated file that you want to read to a data frame. From your other questions, you wish to manipulate these data frames by merging/joining them based on values from a common column.
Google key phrases and look for answers that might help you. In your case, "read tab separated file to R data frame" and "merge data frames based on common values" might be good starting points.
Thank you for trying help, I found a solution myself:
Excellent, congratulations! You're now one step closer to becoming the R expert that will always help you out. I am glad you were able to solve it so fast.
Thank you very much.