2016-08-05 08:55:12 +02:00
|
|
|
window.Chart=function(e){function t(e,t,a){var n=t.steps*t.stepValue,l=e-t.graphMin,o=c(l/n,1,0);return a*t.steps*o}function a(e,t,a,n){function l(){var l=e.animation?c(s(r),null,0):1;g(n),e.scaleOverlay?(a(l),t()):(t(),a(l))}function o(){r+=i,l(),1>=r?w(o):"function"==typeof e.onAnimationComplete&&e.onAnimationComplete()}var i=e.animation?1/c(e.animationSteps,Number.MAX_VALUE,1):1,s=S[e.animationEasing],r=e.animation?0:1;"function"!=typeof t&&(t=function(){}),w(o)}function n(e,t,a,n,o,i){function s(e){return Math.floor(Math.log(e)/Math.LN10)}var r,c,u,d,h,f,S;for(f=n-o,S=s(f),r=Math.floor(o/(1*Math.pow(10,S)))*Math.pow(10,S),c=Math.ceil(n/(1*Math.pow(10,S)))*Math.pow(10,S),u=c-r,d=Math.pow(10,S),h=Math.round(u/d);a>h||h>t;)a>h?(d/=2,h=Math.round(u/d)):(d*=2,h=Math.round(u/d));var p=[];return l(i,p,h,r,d),{steps:h,stepValue:d,graphMin:r,labels:p}}function l(e,t,a,n,l){if(e)for(var o=1;a+1>o;o++)t.push(h(e,{value:(n+l*o).toFixed(u(l))}))}function o(e){return Math.max.apply(Math,e)}function i(e){return Math.min.apply(Math,e)}function s(e,t){return e?e:t}function r(e){return!isNaN(parseFloat(e))&&isFinite(e)}function c(e,t,a){return r(t)&&e>t?t:r(a)&&a>e?a:e}function u(e){return e%1!=0?e.toString().split(".")[1].length:0}function d(e,t){var a={};for(var n in e)a[n]=e[n];for(var n in t)a[n]=t[n];return a}function h(e,t){var a=/\W/.test(e)?new Function("obj","var p=[],print=function(){p.push.apply(p,arguments);};with(obj){p.push('"+e.replace(/[\r\t\n]/g," ").split("<%").join(" ").replace(/((^|%>)[^\t]*)'/g,"$1\r").replace(/\t=(.*?)%>/g,"',$1,'").split(" ").join("');").split("%>").join("p.push('").split("\r").join("\\'")+"');}return p.join('');"):P[e]=P[e]||h(document.getElementById(e).innerHTML);return t?a(t):a}var f=this,S={linear:function(e){return e},easeInQuad:function(e){return e*e},easeOutQuad:function(e){return-1*e*(e-2)},easeInOutQuad:function(e){return(e/=.5)<1?.5*e*e:-0.5*(--e*(e-2)-1)},easeInCubic:function(e){return e*e*e},easeOutCubic:function(e){return 1*((e=e/1-1)*e*e+1)},easeInOutCubic:function(e){return(e/=.5)<1?.5*e*e*e:.5*((e-=2)*e*e+2)},easeInQuart:function(e){return e*e*e*e},easeOutQuart:function(e){return-1*((e=e/1-1)*e*e*e-1)},easeInOutQuart:function(e){return(e/=.5)<1?.5*e*e*e*e:-0.5*((e-=2)*e*e*e-2)},easeInQuint:function(e){return 1*(e/=1)*e*e*e*e},easeOutQuint:function(e){return 1*((e=e/1-1)*e*e*e*e+1)},easeInOutQuint:function(e){return(e/=.5)<1?.5*e*e*e*e*e:.5*((e-=2)*e*e*e*e+2)},easeInSine:function(e){return-1*Math.cos(e/1*(Math.PI/2))+1},easeOutSine:function(e){return 1*Math.sin(e/1*(Math.PI/2))},easeInOutSine:function(e){return-0.5*(Math.cos(Math.PI*e/1)-1)},easeInExpo:function(e){return 0==e?1:1*Math.pow(2,10*(e/1-1))},easeOutExpo:function(e){return 1==e?1:1*(-Math.pow(2,-10*e/1)+1)},easeInOutExpo:function(e){return 0==e?0:1==e?1:(e/=.5)<1?.5*Math.pow(2,10*(e-1)):.5*(-Math.pow(2,-10*--e)+2)},easeInCirc:function(e){return e>=1?e:-1*(Math.sqrt(1-(e/=1)*e)-1)},easeOutCirc:function(e){return 1*Math.sqrt(1-(e=e/1-1)*e)},easeInOutCirc:function(e){return(e/=.5)<1?-0.5*(Math.sqrt(1-e*e)-1):.5*(Math.sqrt(1-(e-=2)*e)+1)},easeInElastic:function(e){var t=1.70158,a=0,n=1;if(0==e)return 0;if(1==(e/=1))return 1;if(a||(a=.3),n<Math.abs(1)){n=1;var t=a/4}else var t=a/(2*Math.PI)*Math.asin(1/n);return-(n*Math.pow(2,10*(e-=1))*Math.sin((1*e-t)*(2*Math.PI)/a))},easeOutElastic:function(e){var t=1.70158,a=0,n=1;if(0==e)return 0;if(1==(e/=1))return 1;if(a||(a=.3),n<Math.abs(1)){n=1;var t=a/4}else var t=a/(2*Math.PI)*Math.asin(1/n);return n*Math.pow(2,-10*e)*Math.sin((1*e-t)*(2*Math.PI)/a)+1},easeInOutElastic:function(e){var t=1.70158,a=0,n=1;if(0==e)return 0;if(2==(e/=.5))return 1;if(a||(a=1*(.3*1.5)),n<Math.abs(1)){n=1;var t=a/4}else var t=a/(2*Math.PI)*Math.asin(1/n);return 1>e?-.5*(n*Math.pow(2,10*(e-=1))*Math.sin((1*e-t)*(2*Math.PI)/a)):n*Math.pow(2,-10*(e-=1))*Math.sin((1*e-t)*(2*Math.PI)/a)*.5+1},easeInBack:function(e){var t=1.70158;return 1*(e/=1)*e*((t+1)*e-t)},easeOutBack:function(e){var t=1.70158;return 1*((e=e/1-1)*e*((t+1)*e+t)+1)},easeInOutBack:function(e){var t=1.70158;return(e/=.5)<1?.5*(e*e*(((t*=1.525
|