diff --git a/phages/scripts/00_create_py_env.sh b/phages/scripts/00_create_py_env.sh new file mode 100644 index 0000000000000000000000000000000000000000..8612ac94ebcff8f271c99e3dd09c3ffd85c63333 --- /dev/null +++ b/phages/scripts/00_create_py_env.sh @@ -0,0 +1,34 @@ +#!/bin/bash + +## VARIABLES + +## Directory containing the virtual environment +py_env_dir=~/envs/coev + +## url for the desired python3 executable +py_version=$(readlink $(command -v python3)) + +echo 'Environment to be installed in: ' $py_env_dir +echo 'Version of python to be used: ' $py_version + + +## SCRIPT + +mkdir -p $py_env_dir +virtualenv -p $py_version $py_env_dir + + +## INSTALL PACKAGES + +# Activate environment +source ${py_env_dir}/bin/activate + +# Update pip if necessary +pip install --upgrade pip + +## +pip install -r requirements_py-env.txt +# pip install biopython pandas matplotlib multiqc pyvcf + + +deactivate diff --git a/phages/scripts/01_quality_check.sh b/phages/scripts/01_quality_check.sh index a84a33f420d0d46c78b8e715c083f81c69237639..74ba96742517c97c36aed20f43dbf48e4093c184 100755 --- a/phages/scripts/01_quality_check.sh +++ b/phages/scripts/01_quality_check.sh @@ -2,11 +2,14 @@ ## PATH TO WORKING DIRECTORY -path=/home/enrique/work/Gandon/coevolution/phages/ +path=$1 +#path=/home/enrique/work/Gandon/coevolution/phages/ + ## START ENVIRONMENT TO EXECUTE MULTIQC -source /home/enrique/envs/biopython/bin/activate + +source ~/envs/coev/bin/activate ## SEPARATE THE FILES BY NAME diff --git a/phages/scripts/07_2_test.py b/phages/scripts/07_2_test.py index 53a686d876934fb9339ba76b2eafbfa5d0255a45..7bc347ab21b80789bce12810640131c8de98502d 100644 --- a/phages/scripts/07_2_test.py +++ b/phages/scripts/07_2_test.py @@ -16,7 +16,8 @@ def run_on_multiple_files(path_to_vcfs, outpath, list_files, list_headers, group -ctrl_file = '/mnt/alpha_raid/work/Gandon/coevolution/phages/results/snpcalling/Other_seq/TO-WT_S83.vcf' +#ctrl_file = '/mnt/alpha_raid/work/Gandon/coevolution/phages/results/snpcalling/Other_seq/TO-WT_S83.vcf' +ctrl_file='/mnt/alpha_raid/work/Gandon/coevolution/phages/steps/snpcalling/Other_seq/TO-WT_S83.vcf' control = ImportControl2() @@ -25,7 +26,7 @@ control.load_vcf(ctrl_file) -path_to_vcfs = '/mnt/alpha_raid/work/Gandon/coevolution/phages/results/snpcalling/W_seq/' +path_to_vcfs = '/mnt/alpha_raid/work/Gandon/coevolution/phages/steps/snpcalling/W_seq/' outpath = '/mnt/alpha_raid/work/Gandon/coevolution/phages/plots/freq_heatmap/W_seq/' diff --git a/phages/scripts/__pycache__/vcf_parser3.cpython-36.pyc b/phages/scripts/__pycache__/vcf_parser3.cpython-36.pyc index 8685296d00265d1349aa4bc3a98dc9e0d78b66ec..2ca4f68efa1f70acb4bc331ef6a9c48523016a0f 100644 Binary files a/phages/scripts/__pycache__/vcf_parser3.cpython-36.pyc and b/phages/scripts/__pycache__/vcf_parser3.cpython-36.pyc differ diff --git a/phages/scripts/requirements_py-env.txt b/phages/scripts/requirements_py-env.txt new file mode 100644 index 0000000000000000000000000000000000000000..162f9da2a84d7ba4b2407626b771c4136ddbd2f1 --- /dev/null +++ b/phages/scripts/requirements_py-env.txt @@ -0,0 +1,31 @@ +biopython==1.76 +certifi==2019.11.28 +chardet==3.0.4 +Click==7.0 +coloredlogs==10.0 +colormath==3.0.0 +cycler==0.10.0 +decorator==4.4.1 +future==0.18.2 +humanfriendly==4.18 +idna==2.8 +Jinja2==2.10.3 +kiwisolver==1.1.0 +lzstring==1.0.4 +Markdown==3.1.1 +MarkupSafe==1.1.1 +matplotlib==2.2.4 +multiqc==1.8 +networkx==2.2 +numpy==1.18.1 +pandas==0.24.2 +pyparsing==2.4.6 +python-dateutil==2.8.1 +pytz==2019.3 +PyVCF==0.6.8 +PyYAML==5.3 +requests==2.22.0 +simplejson==3.17.0 +six==1.13.0 +spectra==0.0.11 +urllib3==1.25.7