Jason Davies
d4459481b2
Add SVG-based treemap example.
2011-07-20 09:07:14 +01:00
Jason Davies
3c2cb84b95
Fix typo and add padding tests.
2011-07-20 08:07:44 +01:00
Mike Bostock
e2187aab37
Add d3.time.scale.
2011-07-19 18:44:04 -07:00
Jason Davies
8e13b182df
Rename nodeRect to pad, and add missing semicolon.
2011-07-19 23:47:00 +01:00
Jason Davies
8ed5d42955
Don't add padding to root node.
...
Also, optimise internal scale() function slightly.
2011-07-19 23:45:15 +01:00
Jason Davies
de9d623169
Add some tests for 0, negative or NaN values.
2011-07-19 23:07:05 +01:00
Jason Davies
55b24ff985
Be smart about padding. Thanks, @mbostock. :)
2011-07-19 22:45:57 +01:00
Jason Davies
4b5cd90c1d
Improvements to padding, thanks to @mbostock.
2011-07-19 21:58:44 +01:00
Jason Davies
62bcec0998
Add support for padding to treemap layout.
...
The new "padding" property is an array of [top, right, bottom, left], or a
function that returns such an array for a given node.
2011-07-19 21:35:19 +01:00
Mike Bostock
e37031a38c
Organize tests into modules.
2011-07-18 18:08:06 -07:00
Mike Bostock
ee74c4608a
Add various time iteration utilities.
2011-07-18 17:56:30 -07:00
Mike Bostock
a40876cb55
Merge branch 'release'
2011-07-16 20:45:11 -07:00
Mike Bostock
0afaaa248f
Update source files.
2011-07-16 20:42:49 -07:00
Mike Bostock
b691732401
Merge branch 'master' of https://github.com/tmont/d3 into release
2011-07-16 20:42:18 -07:00
Mike Bostock
edb8ef17d8
Merge branch 'horizon' of https://github.com/jasondavies/d3 into release
2011-07-16 20:41:26 -07:00
Mike Bostock
0deffc9597
Merge branch 'minor-opt' of https://github.com/jasondavies/d3 into release
2011-07-16 20:40:57 -07:00
Mike Bostock
3d6eba8d19
Merge branch 'force-rangeerror' of https://github.com/jasondavies/d3 into release
2011-07-16 20:40:29 -07:00
Mike Bostock
c31902dd3a
Merge branch 'treemap' of https://github.com/jasondavies/d3 into release
2011-07-16 20:39:09 -07:00
Mike Bostock
25aa1d4df6
Update generated files.
2011-07-16 20:37:08 -07:00
Jason Davies
475f49b6ee
Fix typo.
2011-07-16 18:16:41 +01:00
Jason Davies
1a456a90c7
Minor optimisation.
2011-07-16 00:49:25 +01:00
Tommy Montgomery
5d6ec6b4a7
verify that the node to remove after a transition actually has a parent node
2011-07-14 16:39:34 -07:00
Jason Davies
54a14c7c68
Prevent RangeError in Safari.
...
For very large force layouts, Safari was throwing "RangeError: Maximum call
stack size exceeded". I think this is due to Safari having a smaller call stack
than Chrome and FireFox. In any case, this fix replaces forEach with a while
loop, which should be faster in all browsers as well as reducing the call stack
size needed and thus fixing the Safari issue.
2011-07-14 10:02:43 +01:00
Jason Davies
45d376dbff
Better protection against NaN and negative values.
...
Also, a more symmetric prevention of NaN in the scoring function from Mike:
"rmax is 0 if and only if s is 0, so it is equivalent".
2011-07-12 18:29:55 +01:00
Jason Davies
006bdfe9b8
Better fix for zero-area nodes.
...
Instead of filtering them out, we fix the root of the issue instead, which is
that the scoring function "worst" was returning NaN due to calculating 0/0,
instead of Infinity.
2011-07-12 17:32:20 +01:00
Jason Davies
ae6ce3f373
Ignore negative areas in treemap layout.
2011-07-12 16:48:27 +01:00
Jason Davies
da1006c501
Ignore zero-area nodes in treemap layout.
2011-07-12 16:42:12 +01:00
Caged
6b1a71fcd2
allow access of original data when computing arcs in pie layout
2011-07-11 20:53:57 -07:00
Mike Bostock
06ecb617a2
Allow multiple zoom behaviors to coexist.
...
Any event handlers on the window need to manage global state, as they will be
replaced when another zoom behavior is created.
2011-07-10 10:31:52 -07:00
Mike Bostock
1885dd55c8
Merge branch 'release'
2011-07-09 21:00:51 -07:00
Mike Bostock
c1d7fbc172
Merge branch 'touch' into release
...
This includes nearly a complete rewrite of d3.behavior.zoom, more closely
modeled after the Polymaps po.drag, po.touch and po.wheel classes. This makes
the code simpler and also fixes a bug when releasing one of two fingers.
2011-07-09 20:30:14 -07:00
Mike Bostock
c6c70d4730
Use d3.quantile in d3.chart.box.
2011-07-09 16:03:07 -07:00
Mike Bostock
aa928b6c3e
Merge branch 'jasondavies/force-touch' into release
...
I simplified the implementation to only support single-touch. I also opted not
to include touch support in the force-dynamic example (and other examples), just
because it complicates the examples too much. Touch is nice but I don't want it
to interfere with people learning the basics.
This merge also has an extra bonus fix: you can now have multiple force layouts
with dragging on the same page, and the drag behavior will do the direct the
event to the appropriate force layout.
2011-07-09 15:55:44 -07:00
Mike Bostock
075a8789a4
Add d3.quantile.
2011-07-09 15:15:14 -07:00
Mike Bostock
0bedbd739f
Merge branch 'kde' into release
2011-07-09 14:45:19 -07:00
Mike Bostock
3c8fabbd65
Merge branch 'release'
2011-07-08 22:44:41 -07:00
Mike Bostock
b788ac710f
Merge branch 'force-distance' into release
2011-07-08 22:43:05 -07:00
Mike Bostock
629b13d806
Merge @ignacioola's fix.
2011-07-08 22:42:26 -07:00
Mike Bostock
4cb00f4e92
Add force-directed map example.
2011-07-08 22:39:34 -07:00
Mike Bostock
5c0d8651da
Fix offset when dragging large nodes.
2011-07-08 22:39:08 -07:00
Jason Davies
7f8db7fd14
Remove force.gravityCenter.
...
Simpler to perform gravity calculations in a custom tick handler.
2011-07-09 00:24:17 +01:00
Jason Davies
ca8870778a
Add per-node gravity: force.gravityCenter.
...
This allows the Dorling/Demers cartograms to be slightly closer to the real
geography.
Also, fix the Dorling collision detection as self-collisions were previously
being detected. Thanks, Mike!
Lastly, I've removed the variable per-link distance as this is no longer needed.
2011-07-08 23:23:50 +01:00
Jason Davies
287b2ea59e
Add strokes to Dorling and Demers cartograms.
2011-07-08 22:55:23 +01:00
Jason Davies
9f0e6271f9
Add Demers cartogram example.
...
Like a Dorling cartogram, but with squares instead of circles.
2011-07-08 22:41:01 +01:00
Jason Davies
564418ff62
Nicer colors for Dorling cartogram.
2011-07-08 22:19:28 +01:00
Jason Davies
bb5d7873a7
Use collision detection for Dorling cartogram.
2011-07-08 22:11:49 +01:00
Jason Davies
679d816dfd
Initial version of Dorling cartogram example.
...
This version uses variable-length links, but I think collision detection
performed after initial positioning at state centroids would look better.
2011-07-08 21:55:31 +01:00
Jason Davies
71490ced64
Add missing force.linkStrength property.
...
Also update examples to use force.linkDistance instead of force.distance.
2011-07-08 21:23:41 +01:00
Jason Davies
6a40609624
Add variable link strength (alpha) to force layout.
...
Also, rename force.distance to force.linkDistance, but keep force.distance as an
alias for backwards-compatibility.
Fixes #211 .
2011-07-08 21:20:38 +01:00
Jason Davies
210fb82616
Replace "new Array" with "[]".
...
See <http://jsperf.com/new-array-vs-literal/8 >.
2011-07-08 21:11:34 +01:00