aboutsummaryrefslogtreecommitdiff
path: root/gn2
diff options
context:
space:
mode:
authorzsloan2024-09-18 18:44:11 +0000
committerzsloan2024-09-18 18:53:30 +0000
commit58b4cd559ea5c5dc8381af923573065b488e536c (patch)
tree5d3ecd8a3467ae469a79b96fe5503dae2bf6aea2 /gn2
parent1afae10b6fe838297e465dcc4e94df5eb43490ea (diff)
downloadgenenetwork2-58b4cd559ea5c5dc8381af923573065b488e536c.tar.gz
Make all code related to Spearman Rank scatterplot conditional on not being an Effect Size plot
Diffstat (limited to 'gn2')
-rw-r--r--gn2/wqflask/static/new/javascript/draw_corr_scatterplot.js48
1 files changed, 29 insertions, 19 deletions
diff --git a/gn2/wqflask/static/new/javascript/draw_corr_scatterplot.js b/gn2/wqflask/static/new/javascript/draw_corr_scatterplot.js
index edafed49..fa896621 100644
--- a/gn2/wqflask/static/new/javascript/draw_corr_scatterplot.js
+++ b/gn2/wqflask/static/new/javascript/draw_corr_scatterplot.js
@@ -635,8 +635,10 @@ function chartupdatewh() {
Plotly.newPlot('scatterplot2', getdata(), layout, modebar_options)
Plotly.relayout('scatterplot2', width_height_update)
- Plotly.newPlot('srscatterplot2', srgetdata(), sr_layout, modebar_options)
- Plotly.relayout('srscatterplot2', width_height_update)
+ if (!js_data.effect_plot) {
+ Plotly.newPlot('srscatterplot2', srgetdata(), sr_layout, modebar_options)
+ Plotly.relayout('srscatterplot2', width_height_update)
+ }
}
function colorer(d) {
@@ -712,8 +714,10 @@ function chartupdatedata() {
Plotly.newPlot('scatterplot2', getdata(), layout, modebar_options)
Plotly.relayout('scatterplot2', pearson_title_update)
- Plotly.newPlot('srscatterplot2', srgetdata(), sr_layout, modebar_options)
- Plotly.relayout('srscatterplot2', spearman_title_update)
+ if (!js_data.effect_plot) {
+ Plotly.newPlot('srscatterplot2', srgetdata(), sr_layout, modebar_options)
+ Plotly.relayout('srscatterplot2', spearman_title_update)
+ }
if ($('#cofactor1_type option:selected').val() == "color"){
$('#cofactor_color_selector').css("display", "inline")
@@ -723,11 +727,13 @@ function chartupdatedata() {
'stroke': colorer,
'fill': colorer
});
- d3.select('#srscatterplot2 svg').selectAll('.point')
- .style({
- 'stroke': ranked_colorer,
- 'fill': ranked_colorer
- });
+ if (!js_data.effect_plot) {
+ d3.select('#srscatterplot2 svg').selectAll('.point')
+ .style({
+ 'stroke': ranked_colorer,
+ 'fill': ranked_colorer
+ });
+ }
}
} else if ($('#cofactor2_type option:selected').val() == "color"){
$('#cofactor_color_selector').css("display", "inline")
@@ -737,11 +743,13 @@ function chartupdatedata() {
'stroke': colorer,
'fill': colorer
});
- d3.select('#srscatterplot2 svg').selectAll('.point')
- .style({
- 'stroke': ranked_colorer,
- 'fill': ranked_colorer
- });
+ if (!js_data.effect_plot) {
+ d3.select('#srscatterplot2 svg').selectAll('.point')
+ .style({
+ 'stroke': ranked_colorer,
+ 'fill': ranked_colorer
+ });
+ }
}
} else {
$('#cofactor_color_selector').css("display", "inline")
@@ -751,11 +759,13 @@ function chartupdatedata() {
'stroke': colorer,
'fill': colorer
});
- d3.select('#srscatterplot2 svg').selectAll('.point')
- .style({
- 'stroke': ranked_colorer,
- 'fill': ranked_colorer
- });
+ if (!js_data.effect_plot) {
+ d3.select('#srscatterplot2 svg').selectAll('.point')
+ .style({
+ 'stroke': ranked_colorer,
+ 'fill': ranked_colorer
+ });
+ }
}
}
}