fsolt / dotwhisker

Dot-and-Whisker Plots of Regression Results
https://fsolt.org/dotwhisker/
Other
60 stars 10 forks source link

drop_intercept and more ... #50

Closed bbolker closed 8 years ago

bbolker commented 8 years ago

in addition to the previously discussed drop_intercept, there a few other pieces here (sorry ...) in particular, I added an argument model_name to allow the default ("model") to be overridden

fsolt commented 8 years ago

Looks great, Ben, thanks! One question, though: what's the use case for passing ... to tidy? I know tidy takes them, but I haven't seen an example

bbolker commented 8 years ago

The mixed-model machinery that I was putting together for broom takes arguments specifying e.g. whether you want the fixed effects only, or the variance-covariance parameters (see ?tidy.merMod). So this would be something like

library(lme4)
library(dotwhisker)
gm1 <- glmer(cbind(incidence, size - incidence) ~ period + (1 | herd),
                    data = cbpp, family = binomial)  
dwplot(gm1,effects="fixed")

(update, it wasn't broken, I had just neglected to install the version of dotwhisker I was developing ...)

fsolt commented 8 years ago

Okay, I can see that. I ask because I'd been hoping to use the dots arg to address #42. Ah well, I'm not sure that would have worked anyway.

bbolker commented 8 years ago

wrap dot/whisker aesthetics in a list?

fsolt commented 8 years ago

I think we'll end up just pulling oft-used options and giving them each their own argument. That's what @sammo3182 did for interplot (our other package).