Skip to content

Commit

Permalink
🎨 change heading level and prepare to make it easier to read
Browse files Browse the repository at this point in the history
  • Loading branch information
enryH committed Feb 21, 2025
1 parent 9e91058 commit 289dcf1
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 14 deletions.
16 changes: 9 additions & 7 deletions docs/api_examples/ANCOVA_analysis.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"## Load data.\n",
"# Data for recipe\n",
"Clinical data:"
]
},
Expand Down Expand Up @@ -225,7 +225,7 @@
"id": "ac633c36",
"metadata": {},
"source": [
"### Checking missing data\n",
"## Checking missing data\n",
"... between two AD groups (after previous filtering)"
]
},
Expand Down Expand Up @@ -264,7 +264,9 @@
},
"outputs": [],
"source": [
"data_completeness.T.sort_values(0).plot(style=\".\", ylim=(0, 1.05), alpha=0.5, rot=45)"
"ax = data_completeness.T.sort_values(0).plot(\n",
" style=\".\", ylim=(0, 1.05), alpha=0.5, rot=45\n",
")"
]
},
{
Expand Down Expand Up @@ -312,7 +314,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"## Running ANCOVA analysis\n",
"# ANCOVA analysis for two groups\n",
"Use combined dataset for ANCOVA analysis."
]
},
Expand Down Expand Up @@ -413,7 +415,7 @@
"metadata": {},
"outputs": [],
"source": [
"# ancova.iloc[:, :6]"
"ancova.iloc[:, :6]"
]
},
{
Expand Down Expand Up @@ -465,7 +467,7 @@
"id": "50d10e85",
"metadata": {},
"source": [
"## ANOVA analysis\n",
"# ANOVA analysis for two groups\n",
"not controlling for covariates\n",
"> To check: pvalues for proteins with missing mean values? some merging issue?"
]
Expand Down Expand Up @@ -592,7 +594,7 @@
"id": "69771096",
"metadata": {},
"source": [
"## Comparing ANOVA and ANCOVA results\n",
"# Comparing ANOVA and ANCOVA results for two groups\n",
"Cross tabulated results after FDR correction for both ANOVA and ANCOVA"
]
},
Expand Down
16 changes: 9 additions & 7 deletions docs/api_examples/ANCOVA_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
)

# %% [markdown]
# ## Load data.
# # Data for recipe
# Clinical data:

# %% tags=["hide-input"]
Expand Down Expand Up @@ -108,7 +108,7 @@


# %% [markdown]
# ### Checking missing data
# ## Checking missing data
# ... between two AD groups (after previous filtering)

# %% tags=["hide-input"]
Expand All @@ -122,7 +122,9 @@
# in non-Alzheimer disease group

# %% tags=["hide-input"]
data_completeness.T.sort_values(0).plot(style=".", ylim=(0, 1.05), alpha=0.5, rot=45)
ax = data_completeness.T.sort_values(0).plot(
style=".", ylim=(0, 1.05), alpha=0.5, rot=45
)

# %% [markdown]
# Plot 20 protein groups with biggest difference in missing values between groups
Expand Down Expand Up @@ -150,7 +152,7 @@
)

# %% [markdown]
# ## Running ANCOVA analysis
# # ANCOVA analysis for two groups
# Use combined dataset for ANCOVA analysis.

# %% tags=["hide-input"]
Expand Down Expand Up @@ -193,7 +195,7 @@
# protein group

# %%
# ancova.iloc[:, :6]
ancova.iloc[:, :6]

# %% [markdown]
# The others contain the test results (based on a linear model) for each protein group
Expand All @@ -210,7 +212,7 @@
ancova.iloc[:, 6:].filter(regex=f"^(?!.*({regex_filter})).*$")

# %% [markdown]
# ## ANOVA analysis
# # ANOVA analysis for two groups
# not controlling for covariates
# > To check: pvalues for proteins with missing mean values? some merging issue?

Expand Down Expand Up @@ -267,7 +269,7 @@
anova.drop(columns=viewed_cols)

# %% [markdown]
# ## Comparing ANOVA and ANCOVA results
# # Comparing ANOVA and ANCOVA results for two groups
# Cross tabulated results after FDR correction for both ANOVA and ANCOVA

# %% tags=["hide-input"]
Expand Down

0 comments on commit 289dcf1

Please sign in to comment.