Commit 2e4401c1 authored by zhanxw's avatar zhanxw
Browse files

Merge branch 'master' of

parents d2b292b9 72ab2236
......@@ -546,6 +546,13 @@ To generate empirical kinship (`--inVcf`) on both autosomal region and X chromos
NOTE: you need to provide a pedigree file (PED) in the above case, as `vcf2kinship` needs the sex information of samples to construct kinship for sex chromosome.
For modern genetic datasets, genotype data is often stored by chromosomes, with each chromosome stored in a separate VCF file. In this case, kinship matrix can be first calcualted separately for each chromosome, and then combined using the python script []( Specifically, if you generated two kinship matrices for chr1 chr2 (chr1.kinship, and chr2.kinship), you can run the python script to combine them, i.e.
python -o prefix chr1.kinship chr2.kinship
The resulting kinship matrix is equivalent to the kinship matrix calculated using the merged vcf files.
# Resources
## UCSC RefFlat Genes
#!/usr/bin/env python
import sys, os, re
from XiaoweiLib import myopen
sys.path = [re.sub(r'^/home/zhanxw/', '/net/fantasia/home/zhanxw/', x) for x in sys.path]
from XiaoweiLib import myopen
# convenient functions
def myopen(fn):
import gzip
f =
return open(fn)
def usage():
print("%s -o prefix in1.kinship in2.kinship ..." % sys.argv[0] )
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment