Skip to content

Commit

Permalink
Update documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
gaow committed Aug 16, 2023
1 parent cf40b2d commit dfaa231
Show file tree
Hide file tree
Showing 259 changed files with 61,299 additions and 47,390 deletions.
2 changes: 1 addition & 1 deletion .buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: a87963abbb1285ed80a6ead8e45657fa
config: c107af7d3dded06e26715a49c95b6214
tags: 645f666f9bcd5a90fca523b33c5a78b7
1,243 changes: 676 additions & 567 deletions README.html

Large diffs are not rendered by default.

850 changes: 0 additions & 850 deletions _images/Fine-mapping results plotting.ipynb

This file was deleted.

File renamed without changes
File renamed without changes
File renamed without changes
Binary file added _images/PEER_factor_13_1.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
File renamed without changes
Binary file added _images/covariate_preprocessing_1_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/eQTL_analysis_commands_1_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/genotype_preprocessing_18_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/genotype_preprocessing_19_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/genotype_preprocessing_1_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
File renamed without changes
Binary file added _images/genotype_preprocessing_23_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
File renamed without changes
Binary file added _images/genotype_preprocessing_26_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/phenotype_preprocessing_1_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/rna_quantification.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
:root {
--tabs-color-label-active: hsla(231, 99%, 66%, 1);
--tabs-color-label-inactive: rgba(178, 206, 245, 0.62);
--tabs-color-overline: rgb(207, 236, 238);
--tabs-color-underline: rgb(207, 236, 238);
--tabs-size-label: 1rem;
}
2 changes: 1 addition & 1 deletion _sources/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Developed for reproducible & reusable molecular QTL analyses for the NIH/NIA Alzheimer's Disease Sequencing Project (ADSP) Functional Genomics xQTL (FunGen-xQTL) Project.

![QTL Diagram](code/images/complete_workflow.png)
![QTL Diagram](code/images/xQTL_Protocol_June_2023.png)


## Overview of the protocol
Expand Down
749 changes: 749 additions & 0 deletions _sources/code/data_preprocessing/covariate/PEER_factor.ipynb

Large diffs are not rendered by default.

98 changes: 60 additions & 38 deletions _sources/code/data_preprocessing/genotype/GRM.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"cells": [
{
"cell_type": "markdown",
"id": "bearing-strain",
"id": "constitutional-mining",
"metadata": {
"kernel": "SoS",
"tags": []
Expand All @@ -15,7 +15,7 @@
},
{
"cell_type": "markdown",
"id": "informed-outdoors",
"id": "objective-fitness",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -27,7 +27,7 @@
},
{
"cell_type": "markdown",
"id": "recovered-steering",
"id": "independent-advertising",
"metadata": {
"kernel": "SoS",
"tags": []
Expand All @@ -40,7 +40,7 @@
},
{
"cell_type": "markdown",
"id": "enabling-gibraltar",
"id": "difficult-method",
"metadata": {
"kernel": "SoS",
"tags": []
Expand All @@ -53,7 +53,7 @@
},
{
"cell_type": "markdown",
"id": "correct-commodity",
"id": "governmental-platinum",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -64,7 +64,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "modular-rogers",
"id": "affecting-johns",
"metadata": {
"kernel": "Bash"
},
Expand All @@ -78,7 +78,7 @@
},
{
"cell_type": "markdown",
"id": "religious-exhibition",
"id": "confused-contents",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -89,7 +89,7 @@
{
"cell_type": "code",
"execution_count": 2,
"id": "coordinate-harvest",
"id": "worst-fossil",
"metadata": {
"kernel": "Bash"
},
Expand Down Expand Up @@ -138,7 +138,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "norman-yield",
"id": "brief-extraction",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -149,7 +149,7 @@
"parameter: cwd = path(\"output\")\n",
"# The filename name for output data\n",
"parameter: container = ''\n",
"parameter: entrypoint={('micromamba run -n' + ' ' + container.split('/')[-1][:-4]) if container.endswith('.sif') else f''}\n",
"parameter: entrypoint=('micromamba run -n' + ' ' + container.split('/')[-1][:-4] + \" --no-capture-output\") if container.endswith('.sif') else \"\"\n",
"# For cluster jobs, number commands to run per job\n",
"parameter: job_size = 1\n",
"# Wall clock time expected\n",
Expand Down Expand Up @@ -215,7 +215,7 @@
},
{
"cell_type": "markdown",
"id": "south-subscription",
"id": "opposed-function",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -239,7 +239,7 @@
{
"cell_type": "code",
"execution_count": 1,
"id": "realistic-couple",
"id": "nominated-winner",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -256,7 +256,7 @@
},
{
"cell_type": "markdown",
"id": "directed-penetration",
"id": "associate-turner",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -269,7 +269,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "described-zoning",
"id": "directed-cigarette",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -288,7 +288,7 @@
},
{
"cell_type": "markdown",
"id": "hairy-popularity",
"id": "transparent-spencer",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -299,7 +299,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "expensive-gateway",
"id": "herbal-portugal",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -310,21 +310,33 @@
"output: f'{_input:nn}.apex.grm'\n",
"task: trunk_workers = 1, trunk_size = job_size, walltime = walltime, mem = mem, cores = numThreads, tags = f'{step_name}_{_output:bn}'\n",
"R: expand= \"$[ ]\", stderr = f'{_output}.stderr', stdout = f'{_output}.stdout', container = container, entrypoint=entrypoint\n",
" library(\"dplyr\")\n",
" library(\"tibble\")\n",
" library(\"readr\")\n",
" library(\"purrr\")\n",
" grm = read_delim(gzfile(\"$[_input]\"),\"\\t\",col_names = FALSE)\n",
" id = unlist(read_delim(\"$[_input:n].id\",\"\\t\",col_names = FALSE)[,2])\n",
" grm = grm[,c(1,2,4)]\n",
" colnames(grm) = c(\"#id1\",\"id2\",\"kinship\")\n",
" grm = grm%>%mutate(`#id1` = map_chr(`#id1`, ~id[.x]),`id2` = map_chr(`id2`, ~id[.x]))\n",
" grm%>%write_delim(\"$[_output]\",\"\\t\")"
"\n",
" # Load necessary libraries\n",
" library(dplyr)\n",
" library(readr)\n",
" library(purrr)\n",
"\n",
" # Read data\n",
" grm <- read_delim(gzfile(\"$[_input]\"), '\\t', col_names = FALSE) %>%\n",
" select(1, 2, 4) %>%\n",
" set_names(c(\"#id1\", \"id2\", \"kinship\"))\n",
"\n",
" id <- read_delim(\"$[_input:n].id\", '\\t', col_names = FALSE)[, 2] %>%\n",
" unlist()\n",
"\n",
" # Modify grm data\n",
" grm_updated <- grm %>%\n",
" mutate(`#id1` = map_chr(`#id1`, ~id[.x]),\n",
" `id2` = map_chr(`id2`, ~id[.x]))\n",
"\n",
" # Write to output\n",
" grm_updated %>%\n",
" write_delim(\"$[_output]\", '\\t')"
]
},
{
"cell_type": "markdown",
"id": "interracial-batch",
"id": "printable-freedom",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -335,7 +347,7 @@
{
"cell_type": "code",
"execution_count": null,
"id": "charming-samoa",
"id": "laden-salon",
"metadata": {
"kernel": "SoS"
},
Expand All @@ -346,15 +358,25 @@
"input: group_by = \"all\"\n",
"output: f'{cwd}/{path(list(genotypes.values())[1]):bnn}.loco_grm_list.txt'\n",
"R: expand= \"$[ ]\", stderr = f'{_output}.stderr', stdout = f'{_output}.stdout', container = container, entrypoint=entrypoint\n",
" library(\"dplyr\")\n",
" library(\"tibble\")\n",
" library(\"readr\")\n",
" library(\"purrr\")\n",
" chrom = paste0(\"chr\",c($[paths(genotypes.keys()):r,]),collapse = \"\")\n",
" files = c($[_input:r,])\n",
" dir = \"$[_output:nn]\"\n",
" grm_list = tibble(`#chr` = chrom, dir = files)%>%arrange(`#chr`)\n",
" grm_list%>%write_delim(\"$[_output]\",\"\\t\")"
"\n",
" # Load necessary libraries\n",
" library(dplyr)\n",
" library(readr)\n",
" library(purrr)\n",
"\n",
" # Define chromosomal names\n",
" chromosomes <- paste0(\"chr\", c($[paths(genotypes.keys()):r,]), collapse = \"\")\n",
"\n",
" # Define input files and directory\n",
" input_files <- c($[_input:r,])\n",
"\n",
" # Create and sort the tibble\n",
" grm_tibble <- tibble(`#chr` = chromosomes, dir = input_files) %>%\n",
" arrange(`#chr`)\n",
"\n",
" # Write to output\n",
" grm_tibble %>%\n",
" write_delim(\"$[_output]\", \"\\t\")"
]
}
],
Expand Down Expand Up @@ -389,7 +411,7 @@
"sos"
]
],
"version": "0.24.1"
"version": "0.22.4"
}
},
"nbformat": 4,
Expand Down
Loading

0 comments on commit dfaa231

Please sign in to comment.