Entering edit mode
7.4 years ago
Shicheng Guo
★
9.4k
Hi All,
How to add header to merged matrix from hundreds of bedgraph files:
it should looks like the follow:
ls *bedgraph | xargs bedtools unionbedg -i *.bedgraph -filler NA -header
how to transfer the array from ls *bedgraph
to -header
?
Thanks.
I don't know unionbedg, but why not just
bedtools unionbedg -i *.bedgraph -filler NA -header
?Hi Pierre, I want to transfer the contents of
ls *bedgraph
to-header
, so that the matrix will have the headerthat's precisely what
-header
option does. the above commandbedtools unionbedg -i *.bedgraph -filler NA -header
does exactly what you need.