Recipe for plotting dicts as bars.

This commit is contained in:
yha 2019-08-08 19:05:53 +03:00
parent 3e1258aa0c
commit 9e35cc3fe1

View File

@ -352,7 +352,12 @@ end
end
end
# Dicts with Real values are plotted as bars
@recipe function f(d::AbstractDict{T,<:Real}) where T
seriestype --> :bar
x, y = collect(keys(d)), collect(values(d))
end
# function without range... use the current range of the x-axis