Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Re: Error with plotting. #18

Open
mdhe1248 opened this issue Nov 29, 2015 · 3 comments
Open

Re: Error with plotting. #18

mdhe1248 opened this issue Nov 29, 2015 · 3 comments

Comments

@mdhe1248
Copy link
Contributor

Hi Tim (and Cody),

I am trying to run BlockRegistration.
I get error when I ran plotting. I copied and pasted the error message and my script.

The error message:

julia> plot(x=λs, y=datapenalty, xintercept=λ, Geom.point, Geom.vline, Guide.xlabel("λ"), Guide.ylabel("Data penalty"), Scale.x_log10)
ERROR: MethodError: evalmapping has no method matching evalmapping(::Void, ::Float64)
Closest candidates are:
evalmapping(::Any, ::AbstractArray{T,N})
evalmapping(::Any, ::Function)
evalmapping(::Any, ::Distributions.Distribution{F<:Distributions.VariateForm,S<:Distributions.ValueSupport})
in evalmapping! at /home/donghoon/.julia/v0.4/Gadfly/src/mapping.jl:308
in plot at /home/donghoon/.julia/v0.4/Gadfly/src/Gadfly.jl:316

Original code:
using JLD
using BlockRegistration
using Immerse

fnmm = "/mnt/donghoon_014/OCPI/20151114/exp1_20151114.mm"
Es, cs, Qs, knots, mmis = jldopen(fnmm, mmaparrays=true) do file
read(file, "Es"), read(file, "cs"), read(file, "Qs"), read(file, "knots"), read(file, "mmis")
end;
λmin = 1e-6;
λmax = 100;
ϕ, penalty, λ, λs, datapenalty, quality = auto_λ(10, cs, Qs, knots, mmis, (λmin, λmax))
plot(x=λs, y=datapenalty, xintercept=λ, Geom.point, Geom.vline, Guide.xlabel("λ"), Guide.ylabel("Data penalty"), Scale.x_log10)

@timholy
Copy link
Member

timholy commented Nov 29, 2015

What happens if you leave out the xintercept=λ and Geom.vline parts?

@mdhe1248
Copy link
Contributor Author

It works perfectly!

@timholy
Copy link
Member

timholy commented Nov 29, 2015

I'm going to reopen so I remember to look into why that plot command is broken. Glad it's working, though!

@timholy timholy reopened this Nov 29, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants