From 65b33706d16abb7ef68a815fde5e3b1e69d4638f Mon Sep 17 00:00:00 2001 From: zsloan Date: Wed, 5 Jun 2019 13:15:57 -0500 Subject: Issue where manhattan plot points went past the edge of the plot should be fixed now --- wqflask/wqflask/marker_regression/display_mapping_results.py | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'wqflask') diff --git a/wqflask/wqflask/marker_regression/display_mapping_results.py b/wqflask/wqflask/marker_regression/display_mapping_results.py index e53e5279..043e561a 100644 --- a/wqflask/wqflask/marker_regression/display_mapping_results.py +++ b/wqflask/wqflask/marker_regression/display_mapping_results.py @@ -1868,7 +1868,14 @@ class DisplayMappingResults(object): point_color = pid.grey else: point_color = pid.black - canvas.drawString("5", Xc-canvas.stringWidth("5",font=symbolFont)/2+1,Yc+2,color=point_color, font=symbolFont) + + final_x_pos = Xc-canvas.stringWidth("5",font=symbolFont)/2+1 + if final_x_pos > (xLeftOffset + plotWidth): + break + elif final_x_pos < xLeftOffset: + continue + else: + canvas.drawString("5", final_x_pos,Yc+2,color=point_color, font=symbolFont) else: LRSCoordXY.append((Xc, Yc)) -- cgit v1.2.3