3 ms·
Even if you never end up using it professionally, I think it's worth it to learn D3. The core point that the library makes is that your projection of the data (
by solatic 2y ago
Even if you never end up using it professionally, I think it's worth it to learn D3. The core point that the library makes is that your projection of the data (say, a 1080p screen, 1920x1080) is always different from the dimensions of the data itself (say, grading from 0-100). At some point you need to decide how to scale the data (0-100) so that it draws correctly according to the projection (1920x1080). You can do the math yourself, or you can use a library like D3 to do the math for you.
Even if you don't draw data on the web, you'll probably eventually draw data somewhere, and you'll be glad to look for an equivalent in that ecosystem.
- codetrotter 2y agoOne of the first things I ever programmed in PHP, of my own creation was a binomial distribution graph png generator. Pretty sure I had to scale the rectangles I was drawing for the graph according to the dimensions of the png I was making. It was of course very trivial, and nothing like the amazing things D3 can do. But it was a neat experience, making something of my own for very first time that produced an image on the computer.
- groggo 2y agoThat's a good way of framing the core concept. D3 was never intuitive for me. Maybe the problem is that it tries to do too much, at too many different level of abstraction? If it's just about projecting data, that's easy enough to understand. But I guess projection is also closely tied to axis and other pieces.
- solatic 2y agoI found resources like Scott Murray's "Interactive Data Visualization for the Web" to be invaluable; the D3 docs are too dense/reference-focused for me, but his book introduced the concepts in a slower, more tutorial-like fashion.