Skip to content

Commit

Permalink
Merge pull request #3 from biomedbigdata/dev
Browse files Browse the repository at this point in the history
Dev updates
  • Loading branch information
JohannesKersting authored Nov 15, 2023
2 parents e2b824a + 057c021 commit 09e55c3
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ permissions:
jobs:
deploy:

runs-on: ubuntu-latest
runs-on: self-hosted

steps:
- uses: actions/checkout@v3
Expand Down
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ The patients id or samples ids must be the same in the "expression_data" and "m

In the condition column of the meta DataFrame, the control samples should be encoded as 0 and case samples as 1.

GRN network should be provided a prior, You can either use an experimental validated GRN or learn it from control samples, we recommend using software like [arboreto](https://github.com/aertslab/arboreto), since you can use its output directly to DysRegNet.
The gene regulatory network should be provided by the user. You can either use an experimental validated GRN or learn it from control samples. We recommend using software like [arboreto](https://github.com/aertslab/arboreto) since you can use its output directly to DysRegNet.



Expand All @@ -53,23 +53,23 @@ Additionally, you can provide the following parameters:

- ConCov: List of continuous covariates. They should match the name of their columns in the meta Dataframe.

- zscoring: Boolean, default: True. zscoring of expression data (if needed).
- zscoring: Boolean, default: False. zscoring of expression data (if needed).

- bonferroni_alpha:P-value threshold for multiple testing correction
- bonferroni_alpha: P-value threshold for multiple testing correction

- normaltest: Boolean. If True, Run a normality test for residuals "scipy.stats.normaltest". If residuals are not normal, the edge will not be considered in the analysis.

- normaltest_alpha: p-value threshold for normaltest (if True).

- R2_threshold: R-squared (R2) threshold from 0 to 1 (optional). If the fit is weaker, the edge will not be considered in the analysis.

- direction_condition: Boolean. If True: only include dysregulation that are relevant for the interactions (down regulation of an activation or up regulation of a supressions). Please check the paper for more details.
- direction_condition: Boolean. If True: only include dysregulation that are relevant for the interactions (down-regulation of an activation or up-regulation of a supressions). Please check the paper for more details.


## Get Started


Please note, that the functions are annotated with dockstrings for more details.
Please note that the functions are annotated with dockstrings for more details.

Import the package and pandas:

Expand Down Expand Up @@ -127,11 +127,11 @@ The expected run time for the installation and running the demo dataset on a "no

## The output

The package output a DataFrame that represents patient-specific dysregulated edges. The columns represent edges and the rows patient ids.
The package outputs a data frame that represents patient-specific dysregulated edges. The columns represent edges, and the rows are patient IDs.

In the result table, a value of 0 means that the edge is not significantly dysregulated (different from control samples). Otherwise, the z-score is reported, with a positive in case of activation and a negative sign in case of repression (different than the sign of the residual).

The method "get_results_binary()", outputs binarized dysregulations instead of z-scores.
The method "get_results_binary()" outputs binarized dysregulations instead of z-scores.


## Example
Expand Down
4 changes: 3 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


setup(name='dysregnet',
version='0.0.4',
version='0.0.5',
description='DysRegNet',
long_description=README,
long_description_content_type="text/markdown",
Expand All @@ -24,6 +24,8 @@
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Topic :: Scientific/Engineering :: Bio-Informatics",
],
Expand Down
2 changes: 1 addition & 1 deletion src/dysregnet/functions.py
Original file line number Diff line number Diff line change
Expand Up @@ -105,7 +105,7 @@ def dyregnet_model(data):

# condition of direction
cond = True
direction = np.sign(results.params[1])
direction = np.sign(results.params.iloc[1])


# two sided p_value as default
Expand Down

0 comments on commit 09e55c3

Please sign in to comment.