survHE
survHE copied to clipboard
Style suggestion
https://github.com/giabaio/survHE/blob/f96cd9db50c6e129e1f425114c6bc33f7bdc2a6b/R/make.surv.R#L98
Hi, I'm finding these compound do.call() lines a bit hard to reason about. Can I suggest splitting them up e.g.
make_sim_fns <- paste0("make_sim_", fit$method) make_sim_args <- list(m=m,t=t,X=X,nsim=nsim,newdata=newdata,dist=dist,data=data, formula=fit$misc$formula, summary_stat=summary_stat) sim <- do.call(make_sim_fns, args = make_sim_args)
Thanks!
Thanks @n8thangreen. As I understand, your suggested changes are purely cosmetics, though? So you'd rather have the two separate lines defining the call and args and then the do.call command? If so, that can be easily arranged --- still in the process of getting the devel version on CRAN (should be shortly), then I can change this too.
Did you see this in other places? I think I was using do.call relatively extensively in this release, which works fine for me, TBH, but perhaps can be made clearer for a contributor to look at...