jolars / eulerr

Area-Proportional Euler and Venn Diagrams with Ellipses
https://jolars.github.io/eulerr/
GNU General Public License v3.0
130 stars 18 forks source link

confused by quantitities #43

Closed jxchong closed 5 years ago

jxchong commented 5 years ago

Just came across your package while looking for a replacement for venneuler. I'm confused by your labels and drawings. It seems like the quantities it is showing are not disjoint? Given your example data fit1 in the vignette, I would expect to see that B and C are entirely contained with A, and I would also expect that C would have "0" that is in the section belonging only to C and similarly for B. Am I misunderstanding? Thanks!

fit1 <- euler(c("A" = 25, "B" = 5, "C" = 5,
                 "A&B" = 5, "A&C" = 5, "B&C" = 3,
                 "A&B&C" = 3))
jolars commented 5 years ago

See the documentation for the input argument in euler().

library(euler)
fit1 <- euler(c("A" = 25, "B" = 5, "C" = 5,
                "A&B" = 5, "A&C" = 5, "B&C" = 3,
                "A&B&C" = 3),
              input = "union")
plot(fit1)

Is this what you expect?

image

jxchong commented 5 years ago

Yes that's what I would expect. I see what I was doing wrong, I was giving the input="union" argument to the plot command instead of the fit command (which does not produce an error apparently but also does nothing!) I had been attempting to run plot(fit1, input="union")

jolars commented 5 years ago

I can relate! I might introduce a solution to catch these mistakes in the future.