Dear Pumas
team,
I had a question related to fix some parameters in full Bayesian approach for popPK params estimate.
I tried for using: constantcoef = (ωKa = 0.2, ωCL = 0.2, ωVc = 0.2)
in theopmodel_bayes_v2
in this tutorial but it had an error:
ERROR: MethodError: no method matching fit(::PumasModel{ParamSet{NamedTuple{(:θ, :ωKa, :ωCL, :ωVc, :σ), Tuple{Constrained{DiagNormal, VectorDomain{Vector{Float64}, Vector{Float64}, Vector{Float64}}}, Gamma{Float64}, Gamma{Float64}, Gamma{Float64}, Gamma{Float64}}}}, var"#5#19", var"#6#20", var"#8#22", var"#10#24", Depots1Central1, var"#11#25", var"#15#29", Nothing}, ::Vector{Subject{NamedTuple{(:DV,), Tuple{Vector{Union{Missing, Float64}}}}, Pumas.ConstantCovar{NamedTuple{(:WT,), Tuple{Float64}}}, Vector{Pumas.Event{Float64, Float64, Float64, Float64, Float64, Float64, Int64}}, Vector{Float64}}}, ::NamedTuple{(:θ, :ωKa, :ωCL, :ωVc, :σ), Tuple{Vector{Float64}, Float64, Float64, Float64, Float64}}, ::Pumas.BayesMCMC; constantcoef=(ωKa = 0.2, ωCL = 0.2, ωVc = 0.2), nsamples=2000, nadapts=1000)
Closest candidates are:
fit(::PumasModel, ::AbstractVector{T} where T<:Subject, ::NamedTuple, ::Pumas.BayesMCMC; target_accept, nadapts, nsamples, progress, nchains, rng, diffeq_options) at /builds/PumasAI/PumasSystemImages-jl/.julia/packages/Pumas/XHa5R/src/estimation/bayes.jl:109 got unsupported keyword argument "constantcoef"
fit(::PumasModel, ::AbstractVector{T} where T<:Subject, ::NamedTuple, ::Union{Pumas.LikelihoodApproximation, Pumas.MAP}; optimize_fn, constantcoef, omegas, ensemblealg, checkidentification, diffeq_options) at /builds/PumasAI/PumasSystemImages-jl/.julia/packages/Pumas/XHa5R/src/estimation/likelihoods.jl:2372 got unsupported keyword arguments "nsamples", "nadapts"
fit(::Pumas.PumasEMModel, ::AbstractVector{var"#s35"} where var"#s35"<:Pumas.AbstractSubject, ::NamedTuple, ::Union{Pumas.LikelihoodApproximation, Pumas.MAP}; optimize_fn, constantcoef, ensemblealg, checkidentification, diffeq_options) at /builds/PumasAI/PumasSystemImages-jl/.julia/packages/Pumas/XHa5R/src/estimation/likelihoods.jl:2625 got unsupported keyword arguments "nsamples", "nadapts"
...
Stacktrace:
[1] kwerr(::NamedTuple{(:constantcoef, :nsamples, :nadapts), Tuple{NamedTuple{(:ωKa, :ωCL, :ωVc), Tuple{Float64, Float64, Float64}}, Int64, Int64}}, ::Function, ::PumasModel{ParamSet{NamedTuple{(:θ, :ωKa, :ωCL, :ωVc, :σ), Tuple{Constrained{DiagNormal, VectorDomain{Vector{Float64}, Vector{Float64}, Vector{Float64}}}, Gamma{Float64}, Gamma{Float64}, Gamma{Float64}, Gamma{Float64}}}}, var"#5#19", var"#6#20", var"#8#22", var"#10#24", Depots1Central1, var"#11#25", var"#15#29", Nothing}, ::Vector{Subject{NamedTuple{(:DV,), Tuple{Vector{Union{Missing, Float64}}}}, Pumas.ConstantCovar{NamedTuple{(:WT,), Tuple{Float64}}}, Vector{Pumas.Event{Float64, Float64, Float64, Float64, Float64, Float64, Int64}}, Vector{Float64}}}, ::NamedTuple{(:θ, :ωKa, :ωCL, :ωVc, :σ), Tuple{Vector{Float64}, Float64, Float64, Float64, Float64}}, ::Pumas.BayesMCMC)
@ Base ./error.jl:157
[2] top-level scope
@ REPL[46]:1
Thank you very much for your help!
Tien Nguyen.