You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
library(icenReg)
#> Loading required package: survival#> Loading required package: Rcpp#> Loading required package: codal<- rbinom(n=250, size=1, prob=0.5)
u<- rpois(n=250, lambda=10) +1# erroricenReg::ic_np(data= cbind(l, u))
#> Error in rep(1, nrow(data)): invalid 'times' argument# get next error by manually specifying weights:icenReg::ic_np(data= cbind(l, u), weights= rep(1, times= length(l)))
#> Error in array(x, c(length(x), 1L), if (!is.null(names(x))) list(names(x), : 'data' must be of a vector type, was 'NULL'
but it looks like you intend for the function to be called as icenReg::ic_np(cbind(l, r)), i.e. excluding the data argument when there are no groups. It might be possible to throw a more informative error if ic_np is called without a formula argument yet with a data argument? Or at least tweak the docs / include the fixed version of the above as an example.
Thanks again!
The text was updated successfully, but these errors were encountered:
Hi! Thanks for the package!
I am a bit confused about how to use
ic_np
. I only have one group, so https://github.com/pistacliffcho/icenReg_devel/blob/master/Code/icenReg/R/ic_np.R#L8-L9 makes it seem like I do not need theformula
argument:but it looks like you intend for the function to be called as
icenReg::ic_np(cbind(l, r))
, i.e. excluding thedata
argument when there are no groups. It might be possible to throw a more informative error ific_np
is called without aformula
argument yet with adata
argument? Or at least tweak the docs / include the fixed version of the above as an example.Thanks again!
The text was updated successfully, but these errors were encountered: