-1.6 hsa-miR-3615
-1 hsa-miR-3615
2.8 hsa-miR-5p
-3.8 hsa-miR-5p
how to calculate avg value for particular type of miRNA (like hsa-miR-3615) using perl scripts?
-1.6 hsa-miR-3615
-1 hsa-miR-3615
2.8 hsa-miR-5p
-3.8 hsa-miR-5p
how to calculate avg value for particular type of miRNA (like hsa-miR-3615) using perl scripts?
Using bedtools
:
groupBy -i < in file> -g 2 -c 1 -o mean
output:
hsa-miR-3615 -1.30000000000000004441
hsa-miR-5p -0.5
Thanks for answer goutham.. My file format is csv so i changed command line as "groupBy -i value.csv -g 2 -c 1 -o mean >b.csv", but it takes first two values for this miRNA so what i have to do? i want avg of three values for this miRNA.. 511703.6 hsa-miR-486-5p 503453.6 hsa-miR-486-5p -1.6 hsa-miR-486-5p
Thank you..
Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
What have you tried?
Since you are such a novice in programming/data analysis, why don't you do this with Excel's pivot table function?
i am using perl program for calculation..
thanks for your patience,
We're aware of that. In order to get help, you need to show some code that you wrote that you'd hoped would work. We'll then give you some advise on how to actually get it working correctly.
my %hash; while () { @line=split(\t); push@{hash{$key}}, $value; }
just to store different values for particular miRNA..
actually i am beginar of perl... so i dnt knw hw t write a prgm
If you need to learn some basic programming skills I'd highly suggest doing a course on Coursera or Software Carpentry or something to teach you the basics first. Its hard to teach basic concepts from scratch in a forum like this.
Thanks for your answer goutham. If values for each mirna are more than 2, then how can I use above command?
Thank you, Anitha
-g 2
does not indicate its two rows. Read the manualThanks for your patience Devon...
Anitha