Introduction to D3
What is D3?
See d3js.org.
More TK
The version wars: v3 vs. v4
For ages upon ages D3 version 3 was what everyone was using. As of late, though, they’re up to version 4, bu there’s still plenty of v3 code out there. Watch out!
You can usually tell the difference because version 3 like periods while version 4 likes camelCase: something like d3.scale.linear()
is v3 and d3.scaleLinear()
is v4.
How to open/run a d3 visualization
- Open up Terminal or the Command Prompt
- Use
cd
to navigate to the appropriate directory (a.k.a. folder) - Start a server using
python -m SimpleHTTPServer
orpython -m http.server
(depending on what version of Python you have installed) - Visit http://localhost:8000 in your browser
- Bask in the wonder of your visualization!