From db1e25252ad1a59a3d49f3e276b2f3e88a30c701 Mon Sep 17 00:00:00 2001 From: Oliver Schulz Date: Sun, 30 Jun 2019 17:38:53 +0200 Subject: [PATCH] Fix zero and NaN weighted bins in stephist for log-yscale Bins with weight NaN and zero (which the Plots engine seems to turn into into NaN automatically for log-yscale) should not be draws in log-yscale. --- src/recipes.jl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/recipes.jl b/src/recipes.jl index 705ac54b..cc12b522 100644 --- a/src/recipes.jl +++ b/src/recipes.jl @@ -545,6 +545,8 @@ function _stepbins_path(edge, weights, baseline::Real, xscale::Symbol, yscale::S if !isnan(last_w) push!(x, a) push!(y, baseline) + push!(x, NaN) + push!(y, NaN) end else if isnan(last_w)