As I mentioned in the email I sent we will be releasing a major update to the loo package (this week I hope) and I wanted to follow up and give you a bit more detail specific to your package. When checking the evidence package compatibility with the new loo package I get:
checking examples ... ERROR
Running examples in ‘evidence-Ex.R’ failed
The error most likely occurred in:
> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: looicplot
> ### Title: A dot plot is produced for several related models showing for
> ### each model its LOOIC-value with its credible interval.
> ### Aliases: looicplot
>
... 313 lines ...
0.072735 seconds (Sampling)
0.152936 seconds (Total)
> looicplot(looiclist=list(Mbudworm1, Mbudworm2, Mbudworm3),
+ modnames=c("~ ldose", "~ ldose + sex", "~ ldose * sex"),
+ perc=90)
Warning in ic[i] <- qq[[i]][[3]] :
number of items to replace is not a multiple of replacement length
Error in qq[[i]][[6]] : subscript out of bounds
Calls: looicplot
Execution halted
This is almost certainly happening because the structure of the objects returned by loo has changed slightly to accommodate some of the new features. I believe you only need to change this part inside looicplot:
The new loo objects will have a component estimates which is a matrix from which you can pull the required info. For example, if loo_obj is the result from a call to loo then loo_obj$estimates will be a matrix like this:
I'll send out a follow-up email to my previous one once the loo update is up on CRAN. In the meantime it's now available from the master branch at stan-dev/loo on GitHub if you want to install it.
Hi @rvhulst ,
As I mentioned in the email I sent we will be releasing a major update to the loo package (this week I hope) and I wanted to follow up and give you a bit more detail specific to your package. When checking the evidence package compatibility with the new loo package I get:
This is almost certainly happening because the structure of the objects returned by
loo
has changed slightly to accommodate some of the new features. I believe you only need to change this part insidelooicplot
:The new
loo
objects will have a componentestimates
which is a matrix from which you can pull the required info. For example, ifloo_obj
is the result from a call toloo
thenloo_obj$estimates
will be a matrix like this:I'll send out a follow-up email to my previous one once the loo update is up on CRAN. In the meantime it's now available from the master branch at stan-dev/loo on GitHub if you want to install it.