News for hackers. Stuff that matters.
Re:D3 in Depth by gedy on Thursday May 16, 2024 @12:41PM (#40380397)
Yes same, and I'm curious of what mental modal it uses as it does not register with me, who otherwise has no problem programming.
Re:D3 in Depth by asdman123 on Thursday May 16, 2024 @12:57PM (#40380554)
As far as I remember it is inspired by the Grammar of Graphics, as is ggplot2 in the R ecosystem: https://link.springer.com/book/10.1007/0-387-28695-0

For me it also always had this moment when it „clicked“ just to disappear after not using it for a couple of months.

Re:D3 in Depth by ethbr1 on Thursday May 16, 2024 @01:12PM (#40380746)
Sounds like it's based on a good model for the problem space, but a model that's alien to other day-to-day ones.

Which is an interesting problem!

Is it better to optimally model ones problem space?

Or suboptimally model it, but create a model that's closer to developer/user expectations?

Re:D3 in Depth by grob-gambit on Friday May 17, 2024 @07:18AM (#40388646)
That is exactly it. A big part of the mental model is understanding the concept of tidy data from Hadley Wickham too.

I could not understand some of the design choices until I understood tidy data and not being much into R, I never ran across the idea previously.

Mike Bostock is so brilliant and has put in such an immense amount of work into d3 that if you even start trying to build your own data visualization javascript library you will end up leveraging d3 at some point as to not reinvent the wheel.