Ero sivun ”Widget:Test4” versioiden välillä
Järvi-meriwikistä
Rivi 715: | Rivi 715: | ||
devSum += memo.avgWA[w].dev; | devSum += memo.avgWA[w].dev; | ||
devMax = Math.max( memo.avgWA[w].dev, devMax ); | devMax = Math.max( memo.avgWA[w].dev, devMax ); | ||
− | } | + | } |
+ | devAvg = devSum/devC; | ||
console.log( memo.avgWA ); | console.log( memo.avgWA ); | ||
Rivi 735: | Rivi 736: | ||
memo.seriesA[ memo.seriesA.length - 1 ].obses.push( { | memo.seriesA[ memo.seriesA.length - 1 ].obses.push( { | ||
'x': memo.avgWA[ w ].cDate, | 'x': memo.avgWA[ w ].cDate, | ||
− | 'y': memo.avgWA[ w ].running + memo.avgWA[ w ].dev * 2, | + | 'y': memo.avgWA[ w ].running + Math.max( memo.avgWA[ w ].dev, devAvg ) * 2, |
'style': null, | 'style': null, | ||
'tooltip': '', | 'tooltip': '', |