Bring data to life with SVG, Canvas and HTML. 📊📈🎉
Перейти к файлу
Mike Bostock 1643aa9b46 Merge branch 'master' of https://github.com/trevnorris/d3 into v2.8.0
I simplified the implementation, though it still seems somewhat magical. I
would be more confident if there were an easy way to extract the mantissa and
exponent from a floating point number, but since JavaScript does not expose the
bitwise representation of numbers, there's no easy way to do it.
2012-02-18 13:05:02 -08:00
examples Merge branch 'tweaks' of https://github.com/jasondavies/d3 into v2.8.0 2012-02-18 11:40:32 -08:00
lib Update science.js to 1.7.0: fix science.stats.kde. 2011-09-09 23:37:59 +01:00
src Merge branch 'master' of https://github.com/trevnorris/d3 into v2.8.0 2012-02-18 13:05:02 -08:00
test Merge branch 'master' of https://github.com/trevnorris/d3 into v2.8.0 2012-02-18 13:05:02 -08:00
.gitignore Add .DS_Store to .gitignore. 2011-11-03 09:06:04 -07:00
.gitmodules Replace submodule with package.json. 2011-08-18 10:10:16 -07:00
.npmignore Add .npmignore. 2011-11-18 16:52:35 -08:00
LICENSE Fix typo in LICENSE. 2010-10-10 10:37:07 -07:00
Makefile Update src/package.js rather than package.json. 2012-02-18 11:51:45 -08:00
README.md Add install rule to Makefile. 2011-09-27 13:53:46 -07:00
d3.chart.js Fix typo. 2011-07-16 18:16:41 +01:00
d3.chart.min.js Fix minified file. 2011-12-08 17:55:46 -08:00
d3.csv.js Add test for csv.parse. 2011-08-14 14:37:24 -07:00
d3.csv.min.js Update UglifyJS, JSDOM and Vows. 2011-10-13 11:35:59 +01:00
d3.geo.js add GeometryCollection support to d3.geo.bounds 2011-12-06 16:07:45 -08:00
d3.geo.min.js add GeometryCollection support to d3.geo.bounds 2011-12-06 16:07:45 -08:00
d3.geom.js Fix polygon.centroid for open polygons. 2012-01-29 14:29:14 -08:00
d3.geom.min.js Fix polygon.centroid for open polygons. 2012-01-29 14:29:14 -08:00
d3.js Merge branch 'master' of https://github.com/trevnorris/d3 into v2.8.0 2012-02-18 13:05:02 -08:00
d3.layout.js Merge branch 'tweaks' of https://github.com/jasondavies/d3 into v2.8.0 2012-02-18 11:40:32 -08:00
d3.layout.min.js Prevent next tick when force.stop is called. 2012-02-16 12:49:20 +00:00
d3.min.js Merge branch 'master' of https://github.com/trevnorris/d3 into v2.8.0 2012-02-18 13:05:02 -08:00
d3.time.js Inclusive upper bound for time scale ticks. 2012-01-29 13:44:48 -08:00
d3.time.min.js Inclusive upper bound for time scale ticks. 2012-01-29 13:44:48 -08:00
index.js Add index.js for easier usage within Node. 2012-02-09 09:09:23 -08:00
package.json Add index.js for easier usage within Node. 2012-02-09 09:09:23 -08:00

README.md

D3

D3 is a small, free JavaScript library for manipulating HTML documents based on data. D3 can help you quickly visualize your data as HTML or SVG, handle interactivity, and incorporate smooth transitions and staged animations into your pages. You can use D3 as a visualization framework (like Protovis), or you can use it to build dynamic pages (like jQuery).

Browser Support

D3 should work on any browser, with minimal requirements such as JavaScript and the W3C DOM API. By default D3 requires the Selectors API Level 1, but you can preload Sizzle for compatibility with older browsers. Some of the included D3 examples use additional browser features, such as SVG and CSS3 Transitions. These features are not required to use D3, but are useful for visualization! D3 is not a compatibility layer. The examples should work on Firefox, Chrome (Chromium), Safari (WebKit), Opera and IE9.

Note: Chrome has strict permissions for reading files out of the local file system. Some examples use AJAX which works differently via HTTP instead of local files. For the best experience, load the D3 examples from your own machine via HTTP. Any static file web server will work; for example you can run Python's built-in server:

python -m SimpleHTTPServer 8888

Once this is running, go to: http://localhost:8888/examples/

Development Setup

This repository should work out of the box if you just want to create new visualizations using D3. On the other hand, if you want to extend D3 with new features, fix bugs, or run tests, you'll need to install a few more things.

D3's test framework uses Vows, which depends on Node.js and NPM. If you are developing on Mac OS X, an easy way to install Node and NPM is using Homebrew:

brew install node
brew install npm

Next, from the root directory of this repository, install D3's dependencies:

make install

You can see the list of dependencies in package.json. NPM will install the packages in the node_modules directory.