From 28223e97e3e24c0ac759d7523d701b875cd6df7b Mon Sep 17 00:00:00 2001 From: zsloan Date: Tue, 8 Dec 2020 17:04:41 -0600 Subject: Added method as a parameter for the correlation scatterplot so that it will default to the Spearman tab when the link is from a Spearman correlation --- wqflask/wqflask/correlation/corr_scatter_plot.py | 2 ++ wqflask/wqflask/templates/corr_scatterplot.html | 8 ++++---- wqflask/wqflask/templates/correlation_matrix.html | 3 ++- 3 files changed, 8 insertions(+), 5 deletions(-) (limited to 'wqflask') diff --git a/wqflask/wqflask/correlation/corr_scatter_plot.py b/wqflask/wqflask/correlation/corr_scatter_plot.py index 6ab8c3d8..c87776bb 100644 --- a/wqflask/wqflask/correlation/corr_scatter_plot.py +++ b/wqflask/wqflask/correlation/corr_scatter_plot.py @@ -29,6 +29,8 @@ class CorrScatterPlot(object): self.trait_2 = create_trait(name=params['trait_2'], dataset=self.dataset_2) #self.trait_3 = create_trait(name=params['trait_3'], dataset=self.dataset_3) + self.method = params['method'] + primary_samples = self.dataset_1.group.samplelist if self.dataset_1.group.parlist != None: primary_samples += self.dataset_1.group.parlist diff --git a/wqflask/wqflask/templates/corr_scatterplot.html b/wqflask/wqflask/templates/corr_scatterplot.html index 1133fcd2..cd1998fa 100644 --- a/wqflask/wqflask/templates/corr_scatterplot.html +++ b/wqflask/wqflask/templates/corr_scatterplot.html @@ -118,17 +118,17 @@ {% endif %}
-
+


@@ -243,7 +243,7 @@
-
+


diff --git a/wqflask/wqflask/templates/correlation_matrix.html b/wqflask/wqflask/templates/correlation_matrix.html index 96ad9c35..fb0380c9 100644 --- a/wqflask/wqflask/templates/correlation_matrix.html +++ b/wqflask/wqflask/templates/correlation_matrix.html @@ -32,6 +32,7 @@ {% endfor %} {% for trait in traits %} + {% set outer_loop = loop.index %} @@ -54,7 +55,7 @@ {% if result[1] == 0 %} N/A {% else %} - {{ '%0.2f' % result[1] }}
{{ result[2] }}
+ {{ '%0.2f' % result[1] }}
{{ result[2] }}
{% endif %} {% endif %} {% endfor %} -- cgit v1.2.3