MODAS for Windows/Mac
MODAS runs through Docker in Windows/Mac. Users who do not have Docker installed in the system should first install Docker according to the Docker installation steps in the installation tutorial, and then install MODAS according to the MODAS installation steps. If Docker is already installed in the system, directly refer to the installation steps of MODAS to install MODAS.
Docker installation
For Windows
-
Go to the https://wslstorestorage.blob.core.windows.net/wslblob/wsl_update_x64.msi and download Linux kernel update package file.
-
Then, double-click on the wsl_update_x64.msi to run the installer.
-
Go to the website https://docs.docker.com/docker-for-windows/install/ and download the docker file.
Note: A 64-bit processor and 4GB system RAM are the hardware prerequisites required to successfully run Docker on Windows 10. -
Then, double-click on the Docker Desktop Installer.exe to run the installer.
-
After completion of the installation process, click Close.
For Mac
Please refer https://docs.docker.com/desktop/mac/install/.
MODAS installation
For Windows
- Press Windows+R to open “Run” box. Type “cmd” and then click “OK” to open a regular Command Prompt.
- Then, pull MODAS Image from Docker
docker pull ibreeding/modas:v1
- After pull command is finished, MODAS is installed successfully.
For Mac
- Open the terminal by Spotlight, Applications or Finder.
- Then, pull MODAS Image from Docker
docker pull ibreeding/modas:v1
- After pull command is finished, MODAS is installed successfully.
A toy try
MODAS is a command line-based tool. When using it, user must first open terminals. In Windows, open it through Windows+R and type cmd. In Mac, open it through Spotlight, Applications or Finder.
Note: Running MODAS in Windows/Mac relies on Docker. Make sure that Docker is running when using it.
Running MODAS Image
#For Windows, set /usr/data as working directory by -w,
# mount directory D:/example to /usr/data by -v
docker run -w /usr/data -v D:/example:/usr/data -t -d ibreading/modas:v1 /bin/bash
#For Mac, set /usr/data as working directory by -w, mount directory /Users/macOS_user_account/example to /usr/data by -v
docker run -w /usr/data -v /Users/macOS_user_account/example/example:/usr/data -t -d ibreading/modas:v1 /bin/bash
The -w parameter is used to set the working directory of MODAS, and the -v parameter is used to mount the directory of Windows/Mac to the working directory of MODAS, and is used to generate the running result of MODAS in the directory of Windows/Mac.
After running successfully, MODAS Image will run in the system in the form of a container, through the command
docker ps -a
record the container_id
of MODAS Image ibreeding/modas:v1
for the execution of MODAS.
Generate pseudo-genotype files
docker exec container_id MODAS.py genoidx -g /root/MODAS_data/example_data/example_geno -genome_cluster -o example_geno
Pseudo-genotype files generated by genoidx subcommand will be saved as example_geno.genome_cluster.csv
.
Prescreen candidate genomic regions for omics data
The prescreen subcommand uses genome-wide genotype files to calculate the kinship matrix, first extract genotype files by:
docker exec container_id tar -xvf /root/MODAS_data/genotype/chr_HAMP_genotype.tar.gz
Then, the pseudo-genotype file example_geno.genome_cluster.csv
generated by genoidx
and the example_phe.csv
file under the example_data
folder are used for prescreen analysis,
docker exec container_id MODAS.py prescreen -g /usr/data/chr_HAMP -genome_cluster /usr/data/example_geno.genome_cluster.csv -phe /root/MODAS_data/example_data/example.phe.csv -o example
Prescreen subcommand generates two files including example.sig_omics_phe.csv
containing phenotype data and example.phe_sig_qtl.csv
containing candidate genomic regions of phenotype.
Perform regional association analysis to identify QTLs
The prescreen subcommand outputs are used for regional association analysis,
docker exec container_id MODAS.py regiongwas -g /usr/data/chr_HAMP -phe /usr/data/example.sig_omics_phe.csv -phe_sig_qtl /usr/data/example.phe_sig_qtl.csv -o example
Regiongwas subcommand generates two QTL files including example.region_gwas_qtl_res.csv
containing reliable QTL results and example.region_gwas_bad_qtl_res.csv
containing unreliable QTL results.
Perform Mendelian randomization analysis
docker exec container_id MODAS.py mr -g /usr/data/chr_HAMP -exposure /root/MODAS_data/example_data/example.exp.csv -outcome /root/MODAS_data/agronomic_traits/blup_traits_final.new.csv -qtl /root/MODAS_data/example_data/example_qtl_res.csv -mlm -o example
The results of Mendelian randomization analysis are saved as example.MR.csv
.
MR-based network analysis
MR-based network analysis is carried out by the parameter net of mr subcommand. It uses transcriptome data for subnetwork modules analysis,
docker exec container_id MODAS.py mr -g /usr/data/chr_HAMP -exposure /root/MODAS_data/example_data/network_example.exp.csv -outcome /root/MODAS_data/example_data/network_example.exp.csv -qtl /root/MODAS_data/example_data/network_example_qtl.csv -mlm -net -o network_example
Network analysis generated four files, including network_example.MR.csv
containing gene pairs with MR effect, network_example.edgelist
containing gene pairs with weight, network_example.cluster_one.result.csv
containing all identified subnetwork modules, network_example.sig.cluster_one.result.csv
containing significant subnetwork modules.