Commit 81574b04 authored by Uladzislava KHAURATOVICH's avatar Uladzislava KHAURATOVICH 💬
Browse files

Update !all_species_F_M_Wsnps.md

parent 28ee6e06
......@@ -227,27 +227,29 @@ Prepare the list of W-SNP coordinates
working directory: `/nfs/scistore03/vicosgrp/ukhaurat/full_assembly_analysis/`
```
cat w_snps_perl_script_full_assembly.txt | awk '{print $1, $2}' > w_snps_coordinates.txt
wc w_snps_coordinates.txt
| 181 362 2548 w_snps_coordinates.txt
mv w_snps_coordinates.txt ../all.species.males.females.Wsnps/
```
working directory: `/nfs/scistore03/vicosgrp/ukhaurat/all.species.males.females.Wsnps/`
```
grep -f w_snps_coordinates.txt head.sin.kaz.urm_filtered.vcf > w_snps_all_species.txt
#didn't work
#make a simplified vcf
#remove the filtering for NAs
cat head.sin.kaz.urm_filtered.vcf | grep -v '^##' | perl -pi -e 's/:.*?\t/\t/gi' | perl -pi -e 's/:.*//gi' | perl -pi -e 's/\t/ /gi' | perl -pi -e 's/0\/0/0/gi' | perl -pi -e 's/1\/1/2/gi' | perl -pi -e 's/0\/1/1/gi' > head.sin.kaz.urm_filtered.vcf_simple
cat head.sin.kaz.urm_filtered.vcf | grep -v '^##' | perl -pi -e 's/:.*?\t/\t/gi' | perl -pi -e 's/:.*//gi' | perl -pi -e 's/\t/ /gi' | perl -pi -e 's/0\/0/0/gi' | perl -pi -e 's/1\/1/2/gi' | perl -pi -e 's/0\/1/1/gi' | perl -pi -e 's/\.\/\./NA/gi' > head.sin.kaz.urm_filtered.vcf_simple
grep -f w_snps_coordinates.txt head.sin.kaz.urm_filtered.vcf_simple > w_snps_all_species.txt
#too few
module load vcftools
vcftools --vcf head.sin.kaz.urm_filtered.vcf --snps w_snps_coordinates.txt --recode --recode-INFO-all --out w_snps_all_species.txt
#didn't work
cat w_snps_coordinates.txt | awk '{print $2}' > w_snps_positions.txt
vcftools --vcf head.sin.kaz.urm_filtered.vcf --positions w_snps_positions.txt --recode --recode-INFO-all --out w_snps_all_species.txt
#nothing works!!!!
LG17 59057568 . A G 999 . . GT 0 0 0 0 0 0 0 0 1 1 NA 1 2 2 1 NA 1 2 2 2 2 2
LG17 59057738 . G A 999 . . GT 0 0 0 0 0 0 0 0 1 2 NA 2 1 1 1 NA 1 2 2 2 2 2
LG6 71509373 . C T 480 . . GT 0 0 0 0 0 0 NA 0 1 1 0 0 0 0 0 0 1 1 1 1 1 1
LG6 71663076 . A G 999 . . GT 0 NA 0 0 0 0 0 0 2 2 NA 2 0 0 0 0 2 2 2 2 2 2
LG6 77335125 . G T 767 . . GT 0 0 0 0 0 0 0 0 2 2 2 1 0 0 0 0 1 2 2 2 2 2
LG6 78478436 . C T 999 . . GT 0 0 0 0 0 0 0 0 1 2 NA 2 1 2 2 2 NA 2 2 2 2 2
LG6 78478471 . G T 999 . . GT 0 0 0 0 0 0 0 0 1 2 NA 2 2 2 2 2 2 2 2 2 NA 2
LG6 80088209 . G A 243 . . GT 0 0 0 0 0 0 0 0 1 1 NA 0 1 1 2 2 0 0 0 0 0 0
LG6 84781273 . C T 592 . . GT 0 NA 0 0 0 0 0 0 1 1 NA 0 0 0 0 0 1 1 1 1 1 1
LG6 89149179 . A G 996 . . GT NA 0 0 0 0 0 0 0 1 1 0 1 0 0 0 0 1 2 2 2 2 2
LG6 90659669 . C A 718 . . GT 0 0 0 0 0 0 0 0 1 1 NA 0 0 1 1 1 1 1 1 NA 1 1
LG6 114272754 . C T 999 . . GT NA NA 0 0 0 1 1 1 1 1 0 0 1 1 2 2 2 2 2 2 2 2
LG6 118233256 . G C 860 . . GT 0 0 0 0 0 0 0 0 1 1 NA 0 0 0 0 0 0 2 2 2 2 2
```
Supports Markdown
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