Hi Sam,

Just to be clear, you're using PyPlot.jl in Julia, right?  The way you
wrote the code above doesn't actually run in Julia ("base" is "Base" and
"plt" is "PyPlot"--did you alias those?), and I want to make sure that
you're not doing something like, e.g., using Python and loading pyjulia.

Anyway, assuming that's true...

It's unfortunate that the help is overwritten (might be worth opening an
issue in PyPlot.jl), but in fact, the version in Base is still working just
fine.  In fact, I don't see a way to call the version in PyPlot without
using "PyPlot.hist":

julia> using PyPlot
Warning: Method definition eltype(Any,) in module Base at
abstractarray.jl:10 overwritten in module Compat at
/Users/kevin/.julia/v0.3/Compat/src/Compat.jl:163.
INFO: Loading help data...

julia> hist
hist (generic function with 6 methods)

julia> hist(rand(1:10, 100))    #calls the Base version
(0.0:2.0:10.0,[18,14,21,18,29])

julia> @which hist(rand(1:10, 100))
hist(v::AbstractArray{T,1}) at statistics.jl:599

julia> @which PyPlot.hist(rand(1:10, 100))
hist(args...) at /Users/kevin/.julia/v0.3/PyPlot/src/PyPlot.jl:367

Cheers,
   Kevin


On Wed, Feb 18, 2015 at 10:47 AM, <[email protected]> wrote:

> Hi,
>
> Once I've loaded pyplot, I can't figure out how to use the base.hist
> function. What is the workaround?
>
> help(base.hist) returns the plt.hist functionality.
>

Reply via email to