PopGenome: How to read in multiple reference chromosomes.
1
1
Entering edit mode
9.8 years ago

Hi All -

I'm using the R package PopGenome to analyze WGS data from a VCF file. I read in my VCF and GFF files by chromosome, as described in this post. Now I'd like to verify synonymous and non-synonymous substitutions using the set.synnonsyn() function. The set.synnonsyn() function has a ref.chr = option, but I cannot find any details on what format the input chromosome should take when there are in fact multiple chromosomes in play. Should I feed the program a multifasta? Should I point it to a directory that contains individual chromosome fastas, similar to the way we import multiple VCF and GFF files? I've tried this every way I can think of but no luck.

Any help is much appreciated -

popgenome R population-genetics • 4.2k views
ADD COMMENT
2
Entering edit mode

Hi,

test <- set.synnonsyn(test, ref.chr=c("chr1.fas","chr2.fas", ... ))

should work fine.

Best

ADD REPLY
1
Entering edit mode

UPDATE: I'm side-stepping the issue by reading in chromosomes individually, adding reference metadata individually, then combining each of these individual GENOME objects.

ADD REPLY
2
Entering edit mode
9.8 years ago

Hi,

test <- set.synnonsyn(test, ref.chr=c("chr1.fas","chr2.fas", ... ))

should work fine.

Best

ADD COMMENT
0
Entering edit mode

It works! Thanks, that's brilliant. I should have thought of that myself.

ADD REPLY

Login before adding your answer.

Traffic: 1931 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