Entering edit mode
3.0 years ago
L_to_the_m
▴
10
Hi, I have a VCF file with SNP IDs like this:
AX-14233402__rs35404821
AX-37499887__rs74704183
AX-36783275__rs11997571
I would like to change the SNP IDs to have only the IDs without the AX-...
term:
rs35404821
rs74704183
rs74704183
Is there any solution for this? I tried with a gsub command, but nothing changed:
awk '{gsub(/AX*_rs/,"rs"); print}' datafile.vcf > datafile_ID.vcf
Do not delete posts when they've been addressed. If one or more solutions worked, accept them using the green check mark.
can you try one of these three?