Skip to content

Commit

Permalink
demo: fix spelling
Browse files Browse the repository at this point in the history
  • Loading branch information
miltondp committed Nov 15, 2022
1 parent ed5429a commit e7eef6d
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 18 deletions.
16 changes: 8 additions & 8 deletions nbs/99_demo/01-LV_trait_association-basophil_percentage.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"id": "028ec371",
"metadata": {},
"source": [
"This notebook will show the structure of the main data matrices in PhenoPLIER, and will guide you in analyzing gene associations for a particular trait: basophill percentage, which is presented in the [manuscript](https://greenelab.github.io/phenoplier_manuscript/#phenoplier-an-integration-framework-based-on-gene-co-expression-patterns) in Figure 1c."
"This notebook will show the structure of the main data matrices in PhenoPLIER, and will guide you in analyzing gene associations for a particular trait: basophil percentage, which is presented in the [manuscript](https://greenelab.github.io/phenoplier_manuscript/#phenoplier-an-integration-framework-based-on-gene-co-expression-patterns) in Figure 1c."
]
},
{
Expand Down Expand Up @@ -479,8 +479,8 @@
"PhenomeXcan provides TWAS results (using [Summary-MultiXcan](https://doi.org/10.1371/journal.pgen.1007889) and [Summary-PrediXcan](https://doi.org/10.1038/s41467-018-03621-1)) across ~4,000 traits.\n",
"If you are interested in PhenomeXcan you can also check out the [Github repo](https://github.com/hakyimlab/phenomexcan) to know how to download results.\n",
"\n",
"For this demo, we'll load a file that contains Summary-MultiXcan (or S-MultiXcan) results for basophill percentage.\n",
"This file contains a list of p-values for ~22k genes, where a significant p-value means that the gene's predicted expression (across different tissues) is associated with basophill percentage.\n",
"For this demo, we'll load a file that contains Summary-MultiXcan (or S-MultiXcan) results for basophil percentage.\n",
"This file contains a list of p-values for ~22k genes, where a significant p-value means that the gene's predicted expression (across different tissues) is associated with basophil percentage.\n",
"In the notebook I refer to these results generically as \"TWAS results\", meaning that we have gene-trait associations.\n",
"All these TWAS results were derived solely from GWAS summary stats, so you can also generate yours relatively easily by using [S-MultiXcan](https://doi.org/10.1371/journal.pgen.1007889)."
]
Expand Down Expand Up @@ -572,7 +572,7 @@
],
"source": [
"%%bash\n",
"# download S-MultiXcan results for basophill percentage\n",
"# download S-MultiXcan results for basophil percentage\n",
"wget https://uchicago.box.com/shared/static/g70nq1c6wjvado242t9yg05jrhvdykrv.gz -O /tmp/smultixcan_30220_raw_ccn30.tsv.gz"
]
},
Expand Down Expand Up @@ -808,7 +808,7 @@
"id": "b16b3391",
"metadata": {},
"source": [
"# Take a look at genes associated with basophill percentage"
"# Take a look at genes associated with basophil percentage"
]
},
{
Expand Down Expand Up @@ -846,7 +846,7 @@
"id": "554be85b-71ad-4ef0-806a-317d7ce8a20f",
"metadata": {},
"source": [
"Below I list the top associated genes for basophill percentage."
"Below I list the top associated genes for basophil percentage."
]
},
{
Expand Down Expand Up @@ -1586,7 +1586,7 @@
"source": [
"They do not seem as significant as those within the top genes in LV603.\n",
"\n",
"If we compute the correlation between LV603 gene weights (`lv603_top_genes`) and gene associations for basophill percentage (`traits_df`) we get this:"
"If we compute the correlation between LV603 gene weights (`lv603_top_genes`) and gene associations for basophil percentage (`traits_df`) we get this:"
]
},
{
Expand Down Expand Up @@ -2931,7 +2931,7 @@
"id": "97fdc4d1-7b6c-4352-b12d-b0778a3e8947",
"metadata": {},
"source": [
"As you can see, LV603 is at the top of the LVs associations for basophill percentage.\n",
"As you can see, LV603 is at the top of the LVs associations for basophil percentage.\n",
"However, the onesided p-value here (`5.32e-15`) is larger than a simple correlation (`2.94e-27`), suggesting that we have correlated genes at the top of the LV."
]
},
Expand Down
2 changes: 1 addition & 1 deletion nbs/99_demo/02-LV_cell_types-LV603.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"id": "8310f845",
"metadata": {},
"source": [
"In the previous notebook, we found that LV603 gene weight's are predictive of gene associations for basophill percentage.\n",
"In the previous notebook, we found that LV603 gene weight's are predictive of gene associations for basophil percentage.\n",
"In a real application, you would run the `gls_cli.py` tool for your trait of interest across all LVs in our models, and get the significant ones. Then you can see in which cell types the LVs' genes are expressed, and this is what we are going to do in this notebook for LV603.\n",
"\n",
"To find the cell types associated with an LV, we'll use matrix **B** (see the figure b) below and our [manuscript](https://greenelab.github.io/phenoplier_manuscript/#phenoplier-an-integration-framework-based-on-gene-co-expression-patterns)).\n",
Expand Down
16 changes: 8 additions & 8 deletions nbs/99_demo/py/01-LV_trait_association-basophil_percentage.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# # Description

# %% [markdown]
# This notebook will show the structure of the main data matrices in PhenoPLIER, and will guide you in analyzing gene associations for a particular trait: basophill percentage, which is presented in the [manuscript](https://greenelab.github.io/phenoplier_manuscript/#phenoplier-an-integration-framework-based-on-gene-co-expression-patterns) in Figure 1c.
# This notebook will show the structure of the main data matrices in PhenoPLIER, and will guide you in analyzing gene associations for a particular trait: basophil percentage, which is presented in the [manuscript](https://greenelab.github.io/phenoplier_manuscript/#phenoplier-an-integration-framework-based-on-gene-co-expression-patterns) in Figure 1c.

# %% [markdown]
# # Modules
Expand Down Expand Up @@ -79,13 +79,13 @@
# PhenomeXcan provides TWAS results (using [Summary-MultiXcan](https://doi.org/10.1371/journal.pgen.1007889) and [Summary-PrediXcan](https://doi.org/10.1038/s41467-018-03621-1)) across ~4,000 traits.
# If you are interested in PhenomeXcan you can also check out the [Github repo](https://github.com/hakyimlab/phenomexcan) to know how to download results.
#
# For this demo, we'll load a file that contains Summary-MultiXcan (or S-MultiXcan) results for basophill percentage.
# This file contains a list of p-values for ~22k genes, where a significant p-value means that the gene's predicted expression (across different tissues) is associated with basophill percentage.
# For this demo, we'll load a file that contains Summary-MultiXcan (or S-MultiXcan) results for basophil percentage.
# This file contains a list of p-values for ~22k genes, where a significant p-value means that the gene's predicted expression (across different tissues) is associated with basophil percentage.
# In the notebook I refer to these results generically as "TWAS results", meaning that we have gene-trait associations.
# All these TWAS results were derived solely from GWAS summary stats, so you can also generate yours relatively easily by using [S-MultiXcan](https://doi.org/10.1371/journal.pgen.1007889).

# %% language="bash"
# # download S-MultiXcan results for basophill percentage
# # download S-MultiXcan results for basophil percentage
# wget https://uchicago.box.com/shared/static/g70nq1c6wjvado242t9yg05jrhvdykrv.gz -O /tmp/smultixcan_30220_raw_ccn30.tsv.gz

# %%
Expand All @@ -98,7 +98,7 @@
df.head()

# %% [markdown]
# # Take a look at genes associated with basophill percentage
# # Take a look at genes associated with basophil percentage

# %% [markdown]
# Show the sample size for this trait.
Expand All @@ -109,7 +109,7 @@
display(f"{trait_code} - sample size: {t.n}")

# %% [markdown]
# Below I list the top associated genes for basophill percentage.
# Below I list the top associated genes for basophil percentage.

# %%
traits_df = df[["gene_name", "pvalue"]].dropna().set_index("gene_name")
Expand Down Expand Up @@ -185,7 +185,7 @@
# %% [markdown]
# They do not seem as significant as those within the top genes in LV603.
#
# If we compute the correlation between LV603 gene weights (`lv603_top_genes`) and gene associations for basophill percentage (`traits_df`) we get this:
# If we compute the correlation between LV603 gene weights (`lv603_top_genes`) and gene associations for basophil percentage (`traits_df`) we get this:

# %%
lv603_top_genes
Expand Down Expand Up @@ -245,7 +245,7 @@
lv_df

# %% [markdown]
# As you can see, LV603 is at the top of the LVs associations for basophill percentage.
# As you can see, LV603 is at the top of the LVs associations for basophil percentage.
# However, the onesided p-value here (`5.32e-15`) is larger than a simple correlation (`2.94e-27`), suggesting that we have correlated genes at the top of the LV.

# %% [markdown]
Expand Down
2 changes: 1 addition & 1 deletion nbs/99_demo/py/02-LV_cell_types-LV603.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
# # Description

# %% [markdown]
# In the previous notebook, we found that LV603 gene weight's are predictive of gene associations for basophill percentage.
# In the previous notebook, we found that LV603 gene weight's are predictive of gene associations for basophil percentage.
# In a real application, you would run the `gls_cli.py` tool for your trait of interest across all LVs in our models, and get the significant ones. Then you can see in which cell types the LVs' genes are expressed, and this is what we are going to do in this notebook for LV603.
#
# To find the cell types associated with an LV, we'll use matrix **B** (see the figure b) below and our [manuscript](https://greenelab.github.io/phenoplier_manuscript/#phenoplier-an-integration-framework-based-on-gene-co-expression-patterns)).
Expand Down

0 comments on commit e7eef6d

Please sign in to comment.