たれぱんのびぼーろく

わたしの備忘録、生物学とプログラミングが多いかも

d3.jsとデータの書き換え

入力値やインタラクションの結果をデータとグラフに反映する仕組みはd3.jsに備わっているのか否か

結論

d3.jsには双方向バインディングに該当する仕組みがない.
dataの取得・更新とrebinding、rebinding後の更新が必要. うーむ

There's no data-binding magic à la angular that's going to trigger a "redraw". Just call .data and then re-set the attributes
javascript - How to update bound data in d3.js? - Stack Overflow