Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

breaking down CADD scores file into individual chromosomes #131

Open
samkh918 opened this issue Nov 28, 2020 · 4 comments
Open

breaking down CADD scores file into individual chromosomes #131

samkh918 opened this issue Nov 28, 2020 · 4 comments

Comments

@samkh918
Copy link

Hello, I have broken down the human CADD scores file into individual chromosomes and included all the resulting 24 files in the config file to speed up the annotation process, but it doesn't seem to be the correct way as the log file shows many lines that seem to indicate each variant still goes through all the files:

bix.go:251: chromosome chr1 not found in ...CADD_chr2.vcf.gz
bix.go:251: chromosome chr1 not found in ...CADD_chr3.vcf.gz
bix.go:251: chromosome chr1 not found in ...CADD_chr4.vcf.gz
...

Is it possible to limit the annotation of chr1 variants to CADD_chr1.vcf.gz or would I have to also break down my VCF file into individual chromosomes before attempting the vcfanno annotation with different config files?
Thanks for your help.

@brentp
Copy link
Owner

brentp commented Nov 30, 2020

Hi, vcfanno has to query every file for every variant.
Those logs are just warnings but it's probably faster to have all chroms in one file.

@samkh918
Copy link
Author

Thanks for your help, I also have one other question and sorry if it's been mentioned somewhere else. I was wondering if it's possible to use vcfanno to change the names of previously annotated fields of VCF file or is assigning names only possible at the time of new annotations?
For example my VCF file is already annotated with annovar and I have a "ExAC_ALL" field, I now use vcfanno for other annotation files but I also want to change that previous annovar "ExAC_ALL" to "annovar_ExAC_ALL". I gave it a try with [postannotation] but it wasn't successful:

[[postannotation]]
field=["ExAC_ALL"]
name=["annovar_ExAC_ALL"]
op=["self"]
type="String"

I get the following message after run:

vcfanno version 0.3.2 [built with go1.12.1]

see: https://github.com/brentp/vcfanno
=============================================
panic: toml: cannot load TOML value of type []interface {} into a Go string

goroutine 1 [running]:
main.main()
	/home/brentp/go/src/github.com/brentp/vcfanno/vcfanno.go:85 +0x192e

@brentp
Copy link
Owner

brentp commented Nov 30, 2020

hi, see this section on postannotation. you need e.g.:

[[postannotation]]
fields=["ExAC_ALL"]
name="annovar_ExAC_ALL"
op="self"
type="String"

you can also use delete in postannotationso you can deleteExAC_ALL` after the rename (postannotation blocks are executed in the order given in the toml file).

@samkh918
Copy link
Author

Great thanks a lot!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants