router.html: Support babel cost and BATMAN V in neighbor graph
This patch uses the absolute value for plotting and removes the graph maximum. A dynamic upper margin is introduced to prevent overlap of data and legend. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
This commit is contained in:
parent
00ba4ace1b
commit
825f79aa66
|
@ -124,7 +124,7 @@ function neighbour_graph(neighbours) {
|
||||||
if(quality == null) {
|
if(quality == null) {
|
||||||
quality = 0;
|
quality = 0;
|
||||||
}
|
}
|
||||||
data.push([date_value, quality]);
|
data.push([date_value, Math.abs(quality)]);
|
||||||
}
|
}
|
||||||
catch(TypeError) {
|
catch(TypeError) {
|
||||||
// pass
|
// pass
|
||||||
|
@ -135,7 +135,7 @@ function neighbour_graph(neighbours) {
|
||||||
var plot = $.plot(meshstat, pdata, {
|
var plot = $.plot(meshstat, pdata, {
|
||||||
xaxis: {mode: "time", timezone: "browser"},
|
xaxis: {mode: "time", timezone: "browser"},
|
||||||
selection: {mode: "x"},
|
selection: {mode: "x"},
|
||||||
yaxis: {min: 0, max: 400},
|
yaxis: {min: 0, autoscaleMargin: 0.5},
|
||||||
legend: {noColumns: 2, hideable: true},
|
legend: {noColumns: 2, hideable: true},
|
||||||
series: {downsample: {threshold: Math.floor(meshstat.width() * points_per_px)}}
|
series: {downsample: {threshold: Math.floor(meshstat.width() * points_per_px)}}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue