Question: converting txt to bed
1
gravatar for Fereshteh
23 months ago by
Fereshteh2.8k
Fereshteh2.8k wrote:

i have this txt file by pasting different columns now how i can convert that to bed please because i need a bed then sorting that

i used

[izadi@lbox161 merged_asmribo]$ cut -f 1,2,3,4,5,6 main.txt > main.bed
cut: fields and positions are numbered from 1
Try 'cut --help' for more information.

 FLP1    252    1523
  RAF1    3271    3816
  REP1    1887    3008
  REP2    5308    6198
  YAL069W    335    649
  YAL068W-A    538    792
  YAL067W-A    2480    2707
  YAL066W    10092    10400
  YAL064W-B    12047    12427
  YAL064W    21526    21852

rna-seq • 1.4k views
ADD COMMENTlink modified 22 months ago by Biostar ♦♦ 20 • written 23 months ago by Fereshteh2.8k
1

What you pasted looks like BED file already.
 

ADD REPLYlink written 23 months ago by Devon Ryan73k
1

Devon Ryan is right, your file already looks like a bed file. Are you expecting something different? Perhaps something like:

chr1    252    1523    FLP1
chr2    3271    3816    RAF1
ADD REPLYlink written 23 months ago by h.mon9.2k
1
gravatar for biocyberman
23 months ago by
biocyberman640
Denmark
biocyberman640 wrote:

This requires rather a simple text manipulation trick. The key is that you need to know exactly what you want as a BED file. Read more about BED format here: https://genome.ucsc.edu/FAQ/FAQformat.html#format1

ADD COMMENTlink modified 23 months ago • written 23 months ago by biocyberman640

thank you all, i need gene name, start, end, mapping quality 

ADD REPLYlink written 23 months ago by Fereshteh2.8k
1

You'll need to show what you have to start with. If it's what you posted then you can't add the mapping quality, because you don't know it.

ADD REPLYlink written 23 months ago by Devon Ryan73k

yes you all right thank you, actually i pasted different columns from merged.gtf resulted by cuffmerge to use as a bed contains gene name, start, end for using in biophysconnector package for binning the reads are being mapped on genes

ADD REPLYlink written 23 months ago by Fereshteh2.8k
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 2.3.0
Traffic: 1460 users visited in the last hour