removing a word from a .vcf
0
0
Entering edit mode
15 months ago
matt81rd ▴ 10

Hi all,

I'm aware that this is probanly extremly simple but i can't for the life of me work out how to removing a specific word from a .vcf i am creating.

##fileformat=VCFv4.2
##reference=NC_000962.3
##ALT=<ID=NON_REF,Description="Represents any possible alternative allele at this location">
##INFO=<ID=VARIANT,TYPE=Float,Description="The Gene affected by SNP including the amino acid ref, alt and position">
#CHROM  POS ID  REF ALT QUAL    FILTER  INFO    FORMAT  
ChrI    3987201 .   g   t   .   .   Gene=ddn;Variant=A120S      
ChrI    2714177 .   g   t   .   .   Gene=eis;Variant=L386I      
ChrI    4243489 .   g   t   .   .   Gene=embA;Variant=G86V      
ChrI    4249616 .   g   a   .   .   Gene=embB;Variant=G1035S        
ChrI    4327404 .   g   a   .   .   Gene=ethA;Variant=Q24!      
ChrI    1673851 .   a   g   .   .   Gene=fabG1;Variant=a-351g       
ChrI    4407853 .   c   t   .   .   Gene=gid;Variant=G117E      
ChrI    7971    .   a   g   .   .   Gene=gyrA;Variant=K224E     
ChrI    6736    .   c   a   .   .   Gene=gyrB;Variant=N499K     
ChrI    1674749 .   g   a   .   .   Gene=inhA;Variant=G183D     
ChrI    2155648 .   t   c   .   .   Gene=katG;Variant=Y155C     
ChrI    2288953 .   c   t   .   .   Gene=pncA;Variant=G97S      
ChrI    801268  .   t   c   .   .   Gene=rplC;Variant=C154R     
ChrI    761139  .   ca  ac  .   .   Gene=rpoB;Variant=H445T     
ChrI    781879  .   t   c   .   .   Gene=rpsL;Variant=V107A     
ChrI    1473342 .   g   a   .   .   Gene=rrs;Variant=g1497a     
ChrI    1918625 .   c   g   .   .   Gene=tlyA;Variant=P229R 

I need to remove the word 'FORMAT' on the 5th line but not sure how specifically to do this?

vcf • 539 views
ADD COMMENT
0
0
Entering edit mode

I need to remove the word 'FORMAT' on the 5th line

You could simply open the file in a proper editor (not Word) and delete the word. Assuming you just want to remove that single instance.

Or you could edit in place by sed 's/FORMAT//' your_file.

ADD REPLY

Login before adding your answer.

Traffic: 2185 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6