If you attempt to make a plot with a logarithmic scale and negative numbers, instead of throwing a domain error, some warnings are thrown and an almost empty plot is created. If you then correct the data to be all positive, the returned plot is still messed up and the only way to make it right is to restart julia.
using StatsPlots, DataFrames
df = DataFrame(a = [1, 1, 1, 1, 1, 2, 2, 2, 2, 2], b = repeat([-0.1, 0.1],5))
boxplot(df.a, df.b, yscale = :log10)
┌ Warning: No strict ticks found
└ @ PlotUtils C:\Users\Henri\.julia\packages\PlotUtils\NS6Tf\src\ticks.jl:283
┌ Warning: No strict ticks found
└ @ PlotUtils C:\Users\Henri\.julia\packages\PlotUtils\NS6Tf\src\ticks.jl:283
┌ Warning: No strict ticks found
└ @ PlotUtils C:\Users\Henri\.julia\packages\PlotUtils\NS6Tf\src\ticks.jl:283
boxplot(df.a, max.(0.01, df.b), yscale = :log10)
GKS: Rectangle definition is invalid in routine SET_VIEWPORT
If you attempt to make a plot with a logarithmic scale and negative numbers, instead of throwing a domain error, some warnings are thrown and an almost empty plot is created. If you then correct the data to be all positive, the returned plot is still messed up and the only way to make it right is to restart julia.
the second boxplot returns this: