Skip to content

Commit 5e43a63

Browse files
committed
Fix - correct Y-axis range selection in logarithmic scale
1 parent 1182bf2 commit 5e43a63

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

scripts/JSRootPainter.hist.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2224,6 +2224,7 @@
22242224
fp.CreateXY({ ndim: this.Dimension(),
22252225
check_pad_range: this.check_pad_range,
22262226
create_canvas: this.create_canvas,
2227+
ymin_nz: this.ymin_nz,
22272228
swap_xy: (this.options.BarStyle >= 20),
22282229
reverse_x: this.options.RevX,
22292230
reverse_y: this.options.RevY,

scripts/JSRootPainter.v6.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1175,8 +1175,8 @@
11751175
if (this.scale_ymin>0) break;
11761176
}
11771177

1178-
if ((this.scale_ymin <= 0) && ('ymin_nz' in this) && (this.ymin_nz > 0) && (this.ymin_nz < 1e-2*this.ymax))
1179-
this.scale_ymin = 0.3*this.ymin_nz;
1178+
if ((this.scale_ymin <= 0) && (opts.ymin_nz) && (opts.ymin_nz < 1e-2*this.ymax))
1179+
this.scale_ymin = 0.3 * opts.ymin_nz;
11801180

11811181
if ((this.scale_ymin <= 0) || (this.scale_ymin >= this.scale_ymax))
11821182
this.scale_ymin = 3e-4 * this.scale_ymax;

0 commit comments

Comments
 (0)