Cubism.js, how to see small variations?
I'm testing to render currency pairs prices, but over a 12minute frame
(1000s step * 900 pts size) you end up seeing a horizontal line, though
there are variations of at least 0.001 in prices.
My code is:
d3.select("#graphs").call(function (div) {
div.append("div")
.attr("class", "axis")
.call(context.axis().orient("top"));
div.selectAll(".horizon")
.data(metrics)
.enter().append("div")
.attr("class", "horizon" )
.call(context.horizon()
.format(d3.format(".6s"))
.height(30));
div.append("div")
.attr("class", "rule")
.call(context.rule());
});
I thought it was due to multiple graphs with different extents, or to the
fact it starts with 0 as values, for times before the page load
but I tried to force .extent([1.3335, 1.3337]) for just one graph on the
eurusd pair, yet it was still flat
the problem could be sum up with: http://jsfiddle.net/B2WJM/12/
No comments:
Post a Comment