aboutsummaryrefslogtreecommitdiff
path: root/gn3/computations
diff options
context:
space:
mode:
authorAlexander_Kabui2022-08-10 08:26:10 +0300
committerFrederick Muriuki Muriithi2022-08-10 09:31:13 +0300
commit374cabcb672a0d91eece4b21a83ff3db6afb30bb (patch)
treeda458136fd837cdfd9c0e15c6dfff70493f96381 /gn3/computations
parent08c1486bb853367d5fb93c769d1564ca5f6d1201 (diff)
downloadgenenetwork3-374cabcb672a0d91eece4b21a83ff3db6afb30bb.tar.gz
pylint fixes
Diffstat (limited to 'gn3/computations')
-rw-r--r--gn3/computations/rust_correlation.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/gn3/computations/rust_correlation.py b/gn3/computations/rust_correlation.py
index 54d9243..e7f6bba 100644
--- a/gn3/computations/rust_correlation.py
+++ b/gn3/computations/rust_correlation.py
@@ -49,6 +49,8 @@ def run_correlation(
dataset, trait_vals: str, method: str, delimiter: str,
corr_type: str = "sample", top_n: int = 500):
"""entry function to call rust correlation"""
+
+ #pylint: disable=too-many-arguments
(tmp_dir, tmp_file) = generate_input_files(dataset)
(output_file, json_file) = generate_json_file(
tmp_dir=tmp_dir, tmp_file=tmp_file, method=method, delimiter=delimiter,
@@ -62,6 +64,7 @@ def run_correlation(
def parse_correlation_output(result_file: str,
corr_type: str, top_n: int = 500) -> dict:
"""parse file output """
+ #current types are sample and tissue
def __parse_line__(line):
(trait_name, corr_coeff, p_val, num_overlap) = line.rstrip().split(",")
if corr_type == "sample":
@@ -72,8 +75,7 @@ def parse_correlation_output(result_file: str,
"corr_coefficient": corr_coeff,
"p_value": p_val
})
-
- elif corr_type == "tissue":
+ if corr_type == "tissue":
return (
trait_name,
{