text: var processingObjects=!1;!function(){var n;window.AmCharts?n=window.AmCharts:(n={},(window.AmCharts=n).themes={},n.maps={},n.inheriting={},n.charts=[],n.onReadyArray=[],n.useUTC=!1,n.updateRate=60,n.uid=0,n.lang={},n.translations={},n.mapTranslations={},n.windows={},n.initHandlers=[],n.amString="am",n.pmString="pm"),n.Class=function(t){var e=function(){arguments[0]!==n.inheriting&&(this.events={},this.construct.apply(this,arguments))};for(var i in t.inherits?(e.prototype=new t.inherits(n.inheriting),e.base=t.inherits.prototype,delete t.inherits):(e.prototype.createEvents=function(){for(var t=0;t<arguments.length;t++)this.events[arguments[t]]=[]},e.prototype.listenTo=function(t,e,i){this.removeListener(t,e,i),t.events[e].push({handler:i,scope:this})},e.prototype.addListener=function(t,e,i){this.removeListener(this,t,e),t&&this.events[t]&&this.events[t].push({handler:e,scope:i})},e.prototype.removeListener=function(t,e,i){if(t&&t.events&&(t=t.events[e]))for(e=t.length-1;0<=e;e--)t[e].handler===i&&t.splice(e,1)},e.prototype.fire=function(t){for(var e=this.events[t.type],i=0;i<e.length;i++){var s=e[i];s.handler.call(s.scope,t)}}),t)e.prototype[i]=t[i];return e},n.addChart=function(t){window.requestAnimationFrame?n.animationRequested||(n.animationRequested=!0,window.requestAnimationFrame(n.update)):n.updateInt||(n.updateInt=setInterval(function(){n.update()},Math.round(1e3/n.updateRate))),n.charts.push(t)},n.removeChart=function(t){for(var e=n.charts,i=e.length-1;0<=i;i--)e[i]==t&&e.splice(i,1);0===e.length&&(n.requestAnimation&&(window.cancelAnimationFrame(n.requestAnimation),n.animationRequested=!1),n.updateInt&&(clearInterval(n.updateInt),n.updateInt=NaN))},n.isModern=!0,n.getIEVersion=function(){var t,e=0;return"Microsoft Internet Explorer"==navigator.appName&&(t=navigator.userAgent,null!==/MSIE ([0-9]{1,}[.0-9]{0,})/.exec(t)&&(e=parseFloat(RegExp.$1))),e},n.applyLang=function(t,e){var i=n.translations;e.dayNames=n.extend({},n.dayNames),e.shortDayNames=n.extend({},n.shortDayNames),e.monthNames=n.extend({},n.monthNames),e.shortMonthNames=n.extend({},n.shortMonthNames),e.amString="am",e.pmString="pm",i&&(i=i[t])&&(n.lang=i,(e.langObj=i).monthNames&&(e.dayNames=n.extend({},i.dayNames),e.shortDayNames=n.extend({},i.shortDayNames),e.monthNames=n.extend({},i.monthNames),e.shortMonthNames=n.extend({},i.shortMonthNames)),i.am&&(e.amString=i.am),i.pm&&(e.pmString=i.pm)),n.amString=e.amString,n.pmString=e.pmString},n.IEversion=n.getIEVersion(),n.IEversion<9&&0<n.IEversion&&(n.isModern=!1,n.isIE=!0),n.dx=0,n.dy=0,(document.addEventListener||window.opera)&&(n.isNN=!0,n.isIE=!1,n.dx=.5,n.dy=.5),document.attachEvent&&(n.isNN=!1,n.isIE=!0,n.isModern||(n.dx=0,n.dy=0)),window.chrome&&(n.chrome=!0),n.handleMouseUp=function(t){for(var e=n.charts,i=0;i<e.length;i++){var s=e[i];s&&s.handleReleaseOutside&&s.handleReleaseOutside(t)}},n.handleMouseMove=function(t){for(var e=n.charts,i=0;i<e.length;i++){var s=e[i];s&&s.handleMouseMove&&s.handleMouseMove(t)}},n.handleWheel=function(t){for(var e=n.charts,i=0;i<e.length;i++){var s=e[i];if(s&&s.mouseIsOver){(s.mouseWheelScrollEnabled||s.mouseWheelZoomEnabled)&&s.handleWheel&&(s.handleMouseMove(t),s.handleWheel(t));break}}},n.resetMouseOver=function(){for(var t=n.charts,e=0;e<t.length;e++){var i=t[e];i&&(i.mouseIsOver=!1)}},n.ready=function(t){n.onReadyArray.push(t)},n.handleLoad=function(){n.isReady=!0;for(var t=n.onReadyArray,e=0;e<t.length;e++){var i=t[e];isNaN(n.processDelay)?i():setTimeout(i,n.processDelay*e)}n.onReadyArray=[]},n.addInitHandler=function(t,e){n.initHandlers.push({method:t,types:e})},n.callInitHandler=function(t){var e=n.initHandlers;if(n.initHandlers)for(var i=0;i<e.length;i++){var s=e[i];s.types?n.isInArray(s.types,t.type)&&s.method(t):s.method(t)}},n.getUniqueId=function(){return n.uid++,"AmChartsEl-"+n.uid},n.isNN&&(document.addEventListener("mousemove",n.handleMouseMove),document.addEventListener("mouseup",n.handleMouseUp,!0),window.addEventListener("load",n.handleLoad,!0)),n.isIE&&(document.attachEvent("onmousemove",n.handleMouseMove),document.attachEvent("onmouseup",n.handleMouseUp),window.attachEvent("onload",n.handleLoad)),n.addWheelListeners=function(){n.wheelIsListened||(n.isNN&&(window.addEventListener("DOMMouseScroll",n.handleWheel,!0),document.addEventListener("mousewheel",n.handleWheel,!0)),n.isIE&&document.attachEvent("onmousewheel",n.handleWheel)),n.wheelIsListened=!0},n.clear=function(){var t=n.charts;if(t)for(var e=t.length-1;0<=e;e--)t[e].clear();n.updateInt&&clearInterval(n.updateInt),n.requestAnimation&&window.cancelAnimationFrame(n.requestAnimation),n.charts=[],n.isNN&&(document.removeEventListener("mousemove",n.handleMouseMove,!0),document.removeEventListener("mouseup",n.handleMouseUp,!0),window.removeEventListener("load",n.handleLoad,!0),window.removeEventListener("DOMMouseScroll",n.handleWheel,!0),document.removeEventListener("mousewheel",n.handleWheel,!0)),n.isIE&&(document.detachEvent("onmousemove",n.handleMouseMove),document.detachEvent("onmouseup",n.handleMouseUp),window.detachEvent("onload",n.handleLoad))},n.makeChart=function(t,e,i){var s,a=e.type,o=e.theme;switch(n.isString(o)&&(o=n.themes[o],e.theme=o),a){case"serial":s=new n.AmSerialChart(o);break;case"xy":s=new n.AmXYChart(o);break;case"pie":s=new n.AmPieChart(o);break;case"radar":s=new n.AmRadarChart(o);break;case"gauge":s=new n.AmAngularGauge(o);break;case"funnel":s=new n.AmFunnelChart(o);break;case"map":s=new n.AmMap(o);break;case"stock":s=new n.AmStockChart(o);break;case"gantt":s=new n.AmGanttChart(o)}return n.extend(s,e),n.isReady?isNaN(i)?s.write(t):setTimeout(function(){n.realWrite(s,t)},i):n.ready(function(){isNaN(i)?s.write(t):setTimeout(function(){n.realWrite(s,t)},i)}),s},n.realWrite=function(t,e){t.write(e)},n.updateCount=0,n.validateAt=Math.round(n.updateRate/10),n.update=function(){var t=n.charts;n.updateCount++;var e=!1;if(n.updateCount==n.validateAt&&(e=!0,n.updateCount=0),t)for(var i=t.length-1;0<=i;i--)t[i].update&&t[i].update(),e&&(t[i].autoResize?t[i].validateSize&&t[i].validateSize():t[i].premeasure&&t[i].premeasure());window.requestAnimationFrame&&(n.requestAnimation=window.requestAnimationFrame(n.update))},"complete"==document.readyState&&n.handleLoad()}(),function(){var c=window.AmCharts;c.toBoolean=function(t,e){if(void 0===t)return e;switch(String(t).toLowerCase()){case"true":case"yes":case"1":return!0;case"false":case"no":case"0":case null:return!1;default:return!!t}},c.removeFromArray=function(t,e){var i;if(void 0!==e&&void 0!==t)for(i=t.length-1;0<=i;i--)t[i]==e&&t.splice(i,1)},c.getPath=function(){var t=document.getElementsByTagName("script");if(t)for(var e=0;e<t.length;e++){var i=t[e].src;if(-1!==i.search(/\/(amcharts|ammap)\.js/))return i.replace(/\/(amcharts|ammap)\.js.*/,"/")}},c.normalizeUrl=function(t){return""!==t&&-1===t.search(/\/$/)?t+"/":t},c.isAbsolute=function(t){return 0===t.search(/^http[s]?:|^\//)},c.isInArray=function(t,e){for(var i=0;i<t.length;i++)if(t[i]==e)return!0;return!1},c.getDecimals=function(t){var e=0;return isNaN(t)||(-1!=(t=String(t)).indexOf("e-")?e=Number(t.split("-")[1]):-1!=t.indexOf(".")&&(e=t.split(".")[1].length)),e},c.wordwrap=function(t,e,i,s){var a,o,n,r;if(t+="",e<1)return t;for(a=-1,t=(r=t.split(/\r\n|\n|\r/)).length;++a<t;r[a]+=n){for(n=r[a],r[a]="";n.length>e;r[a]+=c.trim(n.slice(0,o))+((n=n.slice(o)).length?i:""))o=2==s||(o=n.slice(0,e+1).match(/\S*(\s)?$/))[1]?e:o.input.length-o[0].length||1==s&&e||o.input.length+(o=n.slice(e).match(/^\S*/))[0].length;n=c.trim(n)}return r.join(i)},c.trim=function(t){return t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")},c.wrappedText=function(t,e,i,s,a,o,n,r){var h=c.text(t,e,i,s,a,o,n);if(h){var l=h.getBBox();if(l.width>r){var d="\n";c.isModern||(d="<br>"),2<(r=Math.floor(r/(l.width/e.length)))&&(r-=2),e=c.wordwrap(e,r,d,!0),h.remove(),h=c.text(t,e,i,s,a,o,n)}}return h},c.getStyle=function(t,e){var i="";if(document.defaultView&&document.defaultView.getComputedStyle)try{i=document.defaultView.getComputedStyle(t,"").getPropertyValue(e)}catch(t){}else t.currentStyle&&(e=e.replace(/\-(\w)/g,function(t,e){return e.toUpperCase()}),i=t.currentStyle[e]);return i},c.removePx=function(t){if(void 0!==t)return Number(t.substring(0,t.length-2))},c.getURL=function(t,e){if(t)if("_self"!=e&&e)if("_top"==e&&window.top)window.top.location.href=t;else if("_parent"==e&&window.parent)window.parent.location.href=t;else if("_blank"==e)window.open(t);else{var i=document.getElementsByName(e)[0];i?i.src=t:(i=c.windows[e])&&i.opener&&!i.opener.closed?i.location.href=t:c.windows[e]=window.open(t)}else window.location.href=t},c.ifArray=function(t){return!!(t&&"object"==typeof t&&0<t.length)},c.callMethod=function(t,e){var i;for(i=0;i<e.length;i++){var s=e[i];if(s){s[t]&&s[t]();var a,o=s.length;if(0<o)for(a=0;a<o;a++){var n=s[a];n&&n[t]&&n[t]()}}}},c.toNumber=function(t){return"number"==typeof t?t:Number(String(t).replace(/[^0-9\-.]+/g,""))},c.toColor=function(t){if(""!==t&&void 0!==t)if(-1!=t.indexOf(",")){var e;for(t=t.split(","),e=0;e<t.length;e++){var i=t[e].substring(t[e].length-6,t[e].length);t[e]="#"+i}}else t="#"+(t=t.substring(t.length-6,t.length));return t},c.toCoordinate=function(t,e,i){var s;return void 0!==t&&(t=String(t),i&&i<e&&(e=i),s=Number(t),-1!=t.indexOf("!")&&(s=e-Number(t.substr(1))),-1!=t.indexOf("%")&&(s=e*Number(t.substr(0,t.length-1))/100)),s},c.fitToBounds=function(t,e,i){return t<e&&(t=e),i<t&&(t=i),t},c.isDefined=function(t){return void 0!==t},c.stripNumbers=function(t){return t.replace(/[0-9]+/g,"")},c.roundTo=function(t,e){if(e<0)return t;var i=Math.pow(10,e);return Math.round(t*i)/i},c.toFixed=function(t,e){var i=!1;t<0&&(i=!0,t=Math.abs(t));var s=String(Math.round(t*Math.pow(10,e)));if(0<e){var a,o=s.length;if(o<e)for(a=0;a<e-o;a++)s="0"+s;return""===(o=s.substring(0,s.length-e))&&(o=0),s=o+"."+s.substring(s.length-e,s.length),i?"-"+s:s}return String(s)},c.formatDuration=function(t,e,i,s,a,o){var n=c.intervals,r=o.decimalSeparator;if(t>=n[e].contains){var h=t-Math.floor(t/n[e].contains)*n[e].contains;return"ss"==e?1==(h=c.formatNumber(h,o)).split(r)[0].length&&(h="0"+h):h=c.roundTo(h,o.precision),("mm"==e||"hh"==e)&&h<10&&(h="0"+h),i=h+""+s[e]+i,t=Math.floor(t/n[e].contains),e=n[e].nextInterval,c.formatDuration(t,e,i,s,a,o)}if("ss"==e&&1==(t=c.formatNumber(t,o)).split(r)[0].length&&(t="0"+t),"mm"==e&&(t=c.roundTo(t,o.precision)),("mm"==e||"hh"==e)&&t<10&&(t="0"+t),i=t+""+s[e]+i,n[a].count>n[e].count)for(t=n[e].count;t<n[a].count;t++)"ss"==(e=n[e].nextInterval)||"mm"==e||"hh"==e?i="00"+s[e]+i:"DD"==e&&(i="0"+s[e]+i);return":"==i.charAt(i.length-1)&&(i=i.substring(0,i.length-1)),i},c.formatNumber=function(t,e,i,s,a){t=c.roundTo(t,e.precision),isNaN(i)&&(i=e.precision);var o,n=e.decimalSeparator;null==n&&(n=","),null==(e=e.thousandsSeparator)&&(e=" "),o=t<0?"-":"",t=Math.abs(t);var r=!1;-1!=(d=String(t)).indexOf("e")&&(r=!0),0<=i&&!r&&(d=c.toFixed(t,i));var h="";if(r)h=d;else{var l,d=d.split(".");for(l=(r=String(d[0])).length;0<=l;l-=3)h=l!=r.length?0!==l?r.substring(l-3,l)+e+h:r.substring(l-3,l)+h:r.substring(l-3,l);void 0!==d[1]&&(h=h+n+d[1]),void 0!==i&&0<i&&"0"!=h&&(h=c.addZeroes(h,n,i))}return h=o+h,""===o&&!0===s&&0!==t&&(h="+"+h),!0===a&&(h+="%"),h},c.addZeroes=function(t,e,i){return void 0===(t=t.split(e))[1]&&0<i&&(t[1]="0"),t[1].length<i?(t[1]+="0",c.addZeroes(t[0]+e+t[1],e,i)):void 0!==t[1]?t[0]+e+t[1]:t[0]},c.scientificToNormal=function(t){var e,i;if("-"==(t=String(t).split("e"))[1].substr(0,1)){for(e="0.",i=0;i<Math.abs(Number(t[1]))-1;i++)e+="0";e+=t[0].split(".").join("")}else{var s=0;for((e=t[0].split("."))[1]&&(s=e[1].length),e=t[0].split(".").join(""),i=0;i<Math.abs(Number(t[1]))-s;i++)e+="0"}return e},c.toScientific=function(t,e){if(0===t)return"0";var i=Math.floor(Math.log(Math.abs(t))*Math.LOG10E),s=String(s).split(".").join(e);return String(s)+"e"+i},c.randomColor=function(){return"#"+("00000"+(16777216*Math.random()<<0).toString(16)).substr(-6)},c.hitTest=function(t,e,i){var s=!1,a=t.x,o=t.x+t.width,n=t.y,r=t.y+t.height,h=c.isInRectangle;return s||(s=h(a,n,e)),s||(s=h(a,r,e)),s||(s=h(o,n,e)),s||(s=h(o,r,e)),s||!0===i||(s=c.hitTest(e,t,!0)),s},c.isInRectangle=function(t,e,i){return t>=i.x-5&&t<=i.x+i.width+5&&e>=i.y-5&&e<=i.y+i.height+5},c.isPercents=function(t){if(-1!=String(t).indexOf("%"))return!0},c.formatValue=function(t,e,i,s,a,o,n,r){var h;if(e)for(void 0===a&&(a=""),h=0;h<i.length;h++){var l=i[h],d=e[l];void 0!==d&&(d=o?c.addPrefix(d,r,n,s):c.formatNumber(d,s),t=t.replace(new RegExp("\\[\\["+a+l+"\\]\\]","g"),d))}return t},c.formatDataContextValue=function(t,e){if(t){var i,s=t.match(/\[\[.*?\]\]/g);for(i=0;i<s.length;i++){var a;void 0!==e[a=(a=s[i]).substr(2,a.length-4)]&&(t=t.replace(new RegExp("\\[\\["+a+"\\]\\]","g"),e[a]))}}return t},c.massReplace=function(t,e){for(var i in e)if(e.hasOwnProperty(i)){var s=e[i];void 0===s&&(s=""),t=t.replace(i,s)}return t},c.cleanFromEmpty=function(t){return t.replace(/\[\[[^\]]*\]\]/g,"")},c.addPrefix=function(t,e,i,s,a){var o,n,r,h=c.formatNumber(t,s),l="";if(0===t)return"0";if(t<0&&(l="-"),1<(t=Math.abs(t))){for(o=e.length-1;-1<o;o--)if(t>=e[o].number&&(n=t/e[o].number,(r=Number(s.precision))<1&&(r=1),i=c.roundTo(n,r),r=c.formatNumber(i,{precision:-1,decimalSeparator:s.decimalSeparator,thousandsSeparator:s.thousandsSeparator}),!a||n==i)){h=l+""+r+e[o].prefix;break}}else for(o=0;o<i.length;o++)if(t<=i[o].number){n=t/i[o].number,r=Math.abs(Math.floor(Math.log(n)*Math.LOG10E)),h=l+""+(n=c.roundTo(n,r))+i[o].prefix;break}return h},c.remove=function(t){t&&t.remove()},c.getEffect=function(t){return">"==t&&(t="easeOutSine"),"<"==t&&(t="easeInSine"),"elastic"==t&&(t="easeOutElastic"),t},c.getObjById=function(t,e){var i,s;for(s=0;s<t.length;s++){var a=t[s];if(a.id==e){i=a;break}}return i},c.applyTheme=function(t,e,i){e||(e=c.theme);try{e=JSON.parse(JSON.stringify(e))}catch(t){}e&&e[i]&&c.extend(t,e[i])},c.isString=function(t){return"string"==typeof t},c.extend=function(t,e,i){var s;for(s in t||(t={}),e)i&&t.hasOwnProperty(s)||(t[s]=e[s]);return t},c.copyProperties=function(t,e){for(var i in t)t.hasOwnProperty(i)&&"events"!=i&&void 0!==t[i]&&"function"!=typeof t[i]&&"cname"!=i&&(e[i]=t[i])},c.processObject=function(t,e,i,s){if(0==t instanceof e&&(t=s?c.extend(new e(i),t):c.extend(t,new e(i),!0)).listeners)for(var a in t.listeners)e=t.listeners[a],t.addListener(e.event,e.method);return t},c.fixNewLines=function(t){var e=RegExp("\\n","g");return t&&(t=t.replace(e,"<br />")),t},c.fixBrakes=function(t){if(c.isModern){var e=RegExp("<br>","g");t&&(t=t.replace(e,"\n"))}else t=c.fixNewLines(t);return t},c.deleteObject=function(t,e){if(t&&(null==e&&(e=20),0!==e))if("[object Array]"===Object.prototype.toString.call(t))for(var i=0;i<t.length;i++)c.deleteObject(t[i],e-1),t[i]=null;else if(t&&!t.tagName)try{for(i in t.theme=null,t)t[i]&&("object"==typeof t[i]&&c.deleteObject(t[i],e-1),"function"!=typeof t[i]&&(t[i]=null))}catch(t){}},c.bounce=function(t,e,i,s,a){return(e/=a)<1/2.75?7.5625*s*e*e+i:e<2/2.75?s*(7.5625*(e-=1.5/2.75)*e+.75)+i:e<2.5/2.75?s*(7.5625*(e-=2.25/2.75)*e+.9375)+i:s*(7.5625*(e-=2.625/2.75)*e+.984375)+i},c.easeInOutQuad=function(t,e,i,s,a){return(e/=a/2)<1?s/2*e*e+i:-s/2*(--e*(e-2)-1)+i},c.easeInSine=function(t,e,i,s,a){return-s*Math.cos(e/a*(Math.PI/2))+s+i},c.easeOutSine=function(t,e,i,s,a){return s*Math.sin(e/a*(Math.PI/2))+i},c.easeOutElastic=function(t,e,i,s,a){t=1.70158;var o=0,n=s;return 0===e?i:1==(e/=a)?i+s:(o||(o=.3*a),n<Math.abs(s)?(n=s,t=o/4):t=o/(2*Math.PI)*Math.asin(s/n),n*Math.pow(2,-10*e)*Math.sin(2*(e*a-t)*Math.PI/o)+s+i)},c.fixStepE=function(t){t=t.toExponential(0).split("e");var e=Number(t[1]);return 9==Number(t[0])&&e++,c.generateNumber(1,e)},c.generateNumber=function(t,e){var i,s,a="";for(i=e<0?Math.abs(e)-1:Math.abs(e),s=0;s<i;s++)a+="0";return e<0?Number("0."+a+String(t)):Number(String(t)+a)},c.setCN=function(t,e,i,s){if(t.addClassNames&&e&&(e=e.node)&&i){var a=e.getAttribute("class");t=t.classNamePrefix+"-",s&&(t=""),a?e.setAttribute("class",a+" "+t+i):e.setAttribute("class",t+i)}},c.removeCN=function(t,e,i){e&&(e=e.node)&&i&&(e=e.classList)&&e.remove(t.classNamePrefix+"-"+i)},c.parseDefs=function(t,e){for(var i in t){var s=typeof t[i];if(0<t[i].length&&"object"==s)for(var a=0;a<t[i].length;a++)s=document.createElementNS(c.SVG_NS,i),e.appendChild(s),c.parseDefs(t[i][a],s);else"object"==s?(s=document.createElementNS(c.SVG_NS,i),e.appendChild(s),c.parseDefs(t[i],s)):e.setAttribute(i,t[i])}}}(),function(){var h=window.AmCharts;h.AmDraw=h.Class({construct:function(t,e,i,s){h.SVG_NS="http://www.w3.org/2000/svg",h.SVG_XLINK="http://www.w3.org/1999/xlink",h.hasSVG=!!document.createElementNS&&!!document.createElementNS(h.SVG_NS,"svg").createSVGRect,e<1&&(e=10),i<1&&(i=10),this.div=t,this.width=e,this.height=i,this.rBin=document.createElement("div"),h.hasSVG?(h.SVG=!0,e=this.createSvgElement("svg"),t.appendChild(e),this.container=e,this.addDefs(s),this.R=new h.SVGRenderer(this)):h.isIE&&h.VMLRenderer&&(h.VML=!0,h.vmlStyleSheet||(document.namespaces.add("amvml","urn:schemas-microsoft-com:vml"),document.styleSheets.length<31?((e=document.createStyleSheet()).addRule(".amvml","behavior:url(#default#VML); display:inline-block; antialias:true"),h.vmlStyleSheet=e):document.styleSheets[0].addRule(".amvml","behavior:url(#default#VML); display:inline-block; antialias:true")),this.container=t,this.R=new h.VMLRenderer(this,s),this.R.disableSelection(t))},createSvgElement:function(t){return document.createElementNS(h.SVG_NS,t)},circle:function(t,e,i,s){var a=new h.AmDObject("circle",this);return a.attr({r:i,cx:t,cy:e}),this.addToContainer(a.node,s),a},ellipse:function(t,e,i,s,a){var o=new h.AmDObject("ellipse",this);return o.attr({rx:i,ry:s,cx:t,cy:e}),this.addToContainer(o.node,a),o},setSize:function(t,e){0<t&&0<e&&(this.container.style.width=t+"px",this.container.style.height=e+"px")},rect:function(t,e,i,s,a,o,n){var r=new h.AmDObject("rect",this);return h.VML&&(a=Math.round(100*a/Math.min(i,s)),i+=2*o,s+=2*o,r.bw=o,r.node.style.marginLeft=-o,r.node.style.marginTop=-o),i<1&&(i=1),s<1&&(s=1),r.attr({x:t,y:e,width:i,height:s,rx:a,ry:a,"stroke-width":o}),this.addToContainer(r.node,n),r},image:function(t,e,i,s,a,o){var n=new h.AmDObject("image",this);return n.attr({x:e,y:i,width:s,height:a}),this.R.path(n,t),this.addToContainer(n.node,o),n},addToContainer:function(t,e){e||(e=this.container),e.appendChild(t)},text:function(t,e,i){return this.R.text(t,e,i)},path:function(t,e,i,s){var a=new h.AmDObject("path",this);return s||(s="100,100"),a.attr({cs:s}),i?a.attr({dd:t}):a.attr({d:t}),this.addToContainer(a.node,e),a},set:function(t){return this.R.set(t)},remove:function(t){if(t){var e=this.rBin;e.appendChild(t),e.innerHTML=""}},renderFix:function(){var t=this.container,e=t.style;e.top="0px",e.left="0px";try{var i=t.getBoundingClientRect(),s=i.left-Math.round(i.left),a=i.top-Math.round(i.top);s&&(e.left=s+"px"),a&&(e.top=a+"px")}catch(t){}},update:function(){this.R.update()},addDefs:function(t){if(h.hasSVG){var e=this.createSvgElement("desc"),i=this.container;if(i.setAttribute("version","1.1"),i.style.position="absolute",this.setSize(this.width,this.height),t.accessibleTitle){var s=this.createSvgElement("text");i.appendChild(s),s.innerHTML=t.accessibleTitle,s.style.opacity=0}h.rtl&&(i.setAttribute("direction","rtl"),i.style.left="auto",i.style.right="0px"),t&&(t.addCodeCredits&&e.appendChild(document.createTextNode("JavaScript chart by amCharts "+t.version)),t.accessibleDescription&&(e.innerHTML="",e.appendChild(document.createTextNode(t.accessibleDescription))),i.appendChild(e),t.defs&&(e=this.createSvgElement("defs"),i.appendChild(e),h.parseDefs(t.defs,e),this.defs=e))}}})}(),function(){var n=window.AmCharts;n.AmDObject=n.Class({construct:function(t,e){this.D=e,this.R=e.R,this.node=this.R.create(this,t),this.y=this.x=0,this.scale=1},attr:function(t){return this.R.attr(this,t),this},getAttr:function(t){return this.node.getAttribute(t)},setAttr:function(t,e){return this.R.setAttr(this,t,e),this},clipRect:function(t,e,i,s){this.R.clipRect(this,t,e,i,s)},translate:function(t,e,i,s){s||(t=Math.round(t),e=Math.round(e)),this.R.move(this,t,e,i),this.x=t,this.y=e,this.scale=i,this.angle&&this.rotate(this.angle)},rotate:function(t,e){this.R.rotate(this,t,e),this.angle=t},animate:function(t,e,i){for(var s in t)if(t.hasOwnProperty(s)){var a=s,o=t[s];i=n.getEffect(i),this.R.animate(this,a,o,e,i)}},push:function(t){if(t){var e=this.node;e.appendChild(t.node);var i=t.clipPath;i&&e.appendChild(i),(t=t.grad)&&e.appendChild(t)}},text:function(t){this.R.setText(this,t)},remove:function(){this.stop(),this.R.remove(this)},clear:function(){var t=this.node;if(t.hasChildNodes())for(;1<=t.childNodes.length;)t.removeChild(t.firstChild)},hide:function(){this.setAttr("visibility","hidden")},show:function(){this.setAttr("visibility","visible")},getBBox:function(){return this.R.getBBox(this)},toFront:function(){var t=this.node;if(t){this.prevNextNode=t.nextSibling;var e=t.parentNode;e&&e.appendChild(t)}},toPrevious:function(){var t=this.node;t&&this.prevNextNode&&(t=t.parentNode)&&t.insertBefore(this.prevNextNode,null)},toBack:function(){var t=this.node;if(t){this.prevNextNode=t.nextSibling;var e=t.parentNode;if(e){var i=e.firstChild;i&&e.insertBefore(t,i)}}},mouseover:function(t){return this.R.addListener(this,"mouseover",t),this},mouseout:function(t){return this.R.addListener(this,"mouseout",t),this},click:function(t){return this.R.addListener(this,"click",t),this},dblclick:function(t){return this.R.addListener(this,"dblclick",t),this},mousedown:function(t){return this.R.addListener(this,"mousedown",t),this},mouseup:function(t){return this.R.addListener(this,"mouseup",t),this},touchmove:function(t){return this.R.addListener(this,"touchmove",t),this},touchstart:function(t){return this.R.addListener(this,"touchstart",t),this},touchend:function(t){return this.R.addListener(this,"touchend",t),this},keyup:function(t){return this.R.addListener(this,"keyup",t),this},focus:function(t){return this.R.addListener(this,"focus",t),this},blur:function(t){return this.R.addListener(this,"blur",t),this},contextmenu:function(t){return this.node.addEventListener?this.node.addEventListener("contextmenu",t,!0):this.R.addListener(this,"contextmenu",t),this},stop:function(){n.removeFromArray(this.R.animations,this.an_translate),n.removeFromArray(this.R.animations,this.an_y),n.removeFromArray(this.R.animations,this.an_x)},length:function(){return this.node.childNodes.length},gradient:function(t,e,i){this.R.gradient(this,t,e,i)},pattern:function(t,e,i){t&&this.R.pattern(this,t,e,i)}})}(),function(){var c=window.AmCharts;c.SVGRenderer=c.Class({construct:function(t){this.D=t,this.animations=[]},create:function(t,e){return document.createElementNS(c.SVG_NS,e)},attr:function(t,e){for(var i in e)e.hasOwnProperty(i)&&this.setAttr(t,i,e[i])},setAttr:function(t,e,i){void 0!==i&&t.node.setAttribute(e,i)},animate:function(t,e,i,s,a){t.animationFinished=!1;var o=t.node;t["an_"+e]&&c.removeFromArray(this.animations,t["an_"+e]),"translate"==e?0===(o=(o=(o=(o=o.getAttribute("transform"))?String(o).substring(10,o.length-1):"0,0").split(", ").join(" ")).split(" ").join(","))&&(o="0,0"):o=Number(o.getAttribute(e)),i={obj:t,frame:0,attribute:e,from:o,to:i,time:s,effect:a},this.animations.push(i),t["an_"+e]=i},update:function(){var t,e=this.animations;for(t=e.length-1;0<=t;t--){var i,s,a,o=e[t],n=o.time*c.updateRate,r=o.frame+1,h=o.obj,l=o.attribute;if(r<=n){if(o.frame++,"translate"==l){if(i=o.from.split(","),l=Number(i[0]),i=Number(i[1]),isNaN(i)&&(i=0),s=o.to.split(","),a=Number(s[0]),s=Number(s[1]),a=0==a-l?a:Math.round(c[o.effect](0,r,l,a-l,n)),o=0==s-i?s:Math.round(c[o.effect](0,r,i,s-i,n)),l="transform",isNaN(a)||isNaN(o))continue;o="translate("+a+","+o+")"}else s=Number(o.from),a=(i=Number(o.to))-s,o=c[o.effect](0,r,s,a,n),isNaN(o)&&(o=i),0===a&&this.animations.splice(t,1);this.setAttr(h,l,o)}else"translate"==l?(s=o.to.split(","),a=Number(s[0]),s=Number(s[1]),h.translate(a,s)):(i=Number(o.to),this.setAttr(h,l,i)),h.animationFinished=!0,this.animations.splice(t,1)}},getBBox:function(t){if(t=t.node)try{return t.getBBox()}catch(t){}return{width:0,height:0,x:0,y:0}},path:function(t,e){t.node.setAttributeNS(c.SVG_XLINK,"xlink:href",e)},clipRect:function(t,e,i,s,a){var o=t.node,n=t.clipPath;n&&this.D.remove(n);var r=o.parentNode;r&&(o=document.createElementNS(c.SVG_NS,"clipPath"),n=c.getUniqueId(),o.setAttribute("id",n),this.D.rect(e,i,s,a,0,0,o),r.appendChild(o),e="#",c.baseHref&&!c.isIE&&(e=this.removeTarget(window.location.href)+e),this.setAttr(t,"clip-path","url("+e+n+")"),this.clipPathC++,t.clipPath=o)},text:function(t,e,i){var s=new c.AmDObject("text",this.D);t=String(t).split("\n");var a,o=c.removePx(e["font-size"]);for(a=0;a<t.length;a++){var n=this.create(null,"tspan");n.appendChild(document.createTextNode(t[a])),n.setAttribute("y",(o+2)*a+Math.round(o/2)),n.setAttribute("x",0),s.node.appendChild(n)}return s.node.setAttribute("y",Math.round(o/2)),this.attr(s,e),this.D.addToContainer(s.node,i),s},setText:function(t,e){var i=t.node;i&&(i.removeChild(i.firstChild),i.appendChild(document.createTextNode(e)))},move:function(t,e,i,s){isNaN(e)&&(e=0),isNaN(i)&&(i=0),e="translate("+e+","+i+")",s&&(e=e+" scale("+s+")"),this.setAttr(t,"transform",e)},rotate:function(t,e){var i=t.node.getAttribute("transform"),s="rotate("+e+")";i&&(s=i+" "+s),this.setAttr(t,"transform",s)},set:function(t){var e,i=new c.AmDObject("g",this.D);if(this.D.container.appendChild(i.node),t)for(e=0;e<t.length;e++)i.push(t[e]);return i},addListener:function(t,e,i){t.node["on"+e]=i},gradient:function(t,e,i,s){var a=t.node,o=t.grad;if(o&&this.D.remove(o),e=document.createElementNS(c.SVG_NS,e),o=c.getUniqueId(),e.setAttribute("id",o),!isNaN(s)){var n=0,r=0,h=0,l=0;90==s?h=100:270==s?l=100:180==s?n=100:0===s&&(r=100),e.setAttribute("x1",n+"%"),e.setAttribute("x2",r+"%"),e.setAttribute("y1",h+"%"),e.setAttribute("y2",l+"%")}for(s=0;s<i.length;s++)n=document.createElementNS(c.SVG_NS,"stop"),r=100*s/(i.length-1),0===s&&(r=0),n.setAttribute("offset",r+"%"),n.setAttribute("stop-color",i[s]),e.appendChild(n);a.parentNode.appendChild(e),i="#",c.baseHref&&!c.isIE&&(i=this.removeTarget(window.location.href)+i),a.setAttribute("fill","url("+i+o+")"),t.grad=e},removeTarget:function(t){return t.split("#")[0]},pattern:function(t,e,i,s){var a=t.node;isNaN(i)&&(i=1),(o=t.patternNode)&&this.D.remove(o);var o=document.createElementNS(c.SVG_NS,"pattern"),n=c.getUniqueId(),r=e;e.url&&(r=e.url),c.isAbsolute(r)||-1!=r.indexOf("data:image")||(r=s+r),s=Number(e.width),isNaN(s)&&(s=4);var h=Number(e.height);isNaN(h)&&(h=4),s/=i,h/=i,i=e.x,isNaN(i)&&(i=0);var l=-Math.random()*Number(e.randomX);isNaN(l)||(i=l),l=e.y,isNaN(l)&&(l=0);var d=-Math.random()*Number(e.randomY);isNaN(d)||(l=d),o.setAttribute("id",n),o.setAttribute("width",s),o.setAttribute("height",h),o.setAttribute("patternUnits","userSpaceOnUse"),o.setAttribute("xlink:href",r),e.color&&((d=document.createElementNS(c.SVG_NS,"rect")).setAttributeNS(null,"height",s),d.setAttributeNS(null,"width",h),d.setAttributeNS(null,"fill",e.color),o.appendChild(d)),this.D.image(r,0,0,s,h,o).translate(i,l),r="#",c.baseHref&&!c.isIE&&(r=this.removeTarget(window.location.href)+r),a.setAttribute("fill","url("+r+n+")"),t.patternNode=o,a.parentNode.appendChild(o)},remove:function(t){t.clipPath&&this.D.remove(t.clipPath),t.grad&&this.D.remove(t.grad),t.patternNode&&this.D.remove(t.patternNode),this.D.remove(t.node)}})}(),function(){var c=window.AmCharts;c.AmChart=c.Class({construct:function(t){this.svgIcons=this.tapToActivate=!0,this.theme=t,this.classNamePrefix="amcharts",this.addClassNames=!1,this.version="3.21.13",c.addChart(this),this.createEvents("buildStarted","dataUpdated","init","rendered","drawn","failed","resized","animationFinished"),this.height=this.width="100%",this.dataChanged=!0,this.chartCreated=!1,this.previousWidth=this.previousHeight=0,this.backgroundColor="#FFFFFF",this.borderAlpha=this.backgroundAlpha=0,this.color=this.borderColor="#000000",this.fontFamily="Verdana",this.fontSize=11,this.usePrefixes=!1,this.autoResize=!0,this.autoDisplay=!1,this.addCodeCredits=this.accessible=!0,this.touchStartTime=this.touchClickDuration=0,this.precision=-1,this.percentPrecision=2,this.decimalSeparator=".",this.thousandsSeparator=",",this.labels=[],this.allLabels=[],this.titles=[],this.marginRight=this.marginLeft=this.autoMarginOffset=0,this.timeOuts=[],this.creditsPosition="top-left";var e=document.createElement("div"),i=e.style;i.overflow="hidden",i.position="relative",i.textAlign="left",this.chartDiv=e,(i=(e=document.createElement("div")).style).overflow="hidden",i.position="relative",i.textAlign="left",this.legendDiv=e,this.titleHeight=0,this.hideBalloonTime=150,this.handDrawScatter=2,this.cssScale=this.handDrawThickness=1,this.cssAngle=0,this.prefixesOfBigNumbers=[{number:1e3,prefix:"k"},{number:1e6,prefix:"M"},{number:1e9,prefix:"G"},{number:1e12,prefix:"T"},{number:1e15,prefix:"P"},{number:1e18,prefix:"E"},{number:1e21,prefix:"Z"},{number:1e24,prefix:"Y"}],this.prefixesOfSmallNumbers=[{number:1e-24,prefix:"y"},{number:1e-21,prefix:"z"},{number:1e-18,prefix:"a"},{number:1e-15,prefix:"f"},{number:1e-12,prefix:"p"},{number:1e-9,prefix:"n"},{number:1e-6,prefix:"μ"},{number:.001,prefix:"m"}],this.panEventsEnabled=!0,this.product="amcharts",this.animations=[],this.balloon=new c.AmBalloon(this.theme),(this.balloon.chart=this).processTimeout=0,this.processCount=1e3,this.animatable=[],this.langObj={},c.applyTheme(this,t,"AmChart")},drawChart:function(){0<this.realWidth&&0<this.realHeight&&(this.drawBackground(),this.redrawLabels(),this.drawTitles(),this.renderFix(),this.chartDiv&&(this.boundingRect=this.chartDiv.getBoundingClientRect()))},makeAccessible:function(t,e,i){this.accessible&&t&&(i&&t.setAttr("role",i),t.setAttr("aria-label",e))},drawBackground:function(){c.remove(this.background);var t=this.container,e=this.backgroundColor,i=this.backgroundAlpha,s=this.set;c.isModern||0!==i||(i=.001);var a=this.updateWidth();this.realWidth=a;var o=this.updateHeight();this.realHeight=o,e=c.polygon(t,[0,a-1,a-1,0],[0,0,o-1,o-1],e,i,1,this.borderColor,this.borderAlpha),c.setCN(this,e,"bg"),this.background=e,s.push(e),(e=this.backgroundImage)&&(t=t.image(e,0,0,a,o),c.setCN(this,e,"bg-image"),this.bgImg=t,s.push(t))},drawTitles:function(t){var e=this.titles;if(this.titleHeight=0,c.ifArray(e)){var i,s=20;for(i=0;i<e.length;i++){var a=e[i];if(!1!==(a=c.processObject(a,c.Title,this.theme)).enabled){var o=a.color;void 0===o&&(o=this.color);var n=a.size;isNaN(n)&&(n=this.fontSize+2),isNaN(a.alpha);var r=this.marginLeft,h=!0;void 0!==a.bold&&(h=a.bold),(o=c.wrappedText(this.container,a.text,o,this.fontFamily,n,"middle",h,this.realWidth-35-this.marginRight-r)).translate(r+(this.realWidth-this.marginRight-r)/2,s),o.node.style.pointerEvents="none",a.sprite=o,void 0!==a.tabIndex&&o.setAttr("tabindex",a.tabIndex),c.setCN(this,o,"title"),a.id&&c.setCN(this,o,"title-"+a.id),o.attr({opacity:a.alpha}),s+=o.getBBox().height+5,t?o.remove():this.freeLabelsSet.push(o)}}this.titleHeight=s-10}},write:function(t){var e=this;if(e.listeners)for(var i=0;i<e.listeners.length;i++){var s=e.listeners[i];e.addListener(s.event,s.method)}e.fire({type:"buildStarted",chart:e}),e.afterWriteTO&&clearTimeout(e.afterWriteTO),0<e.processTimeout?e.afterWriteTO=setTimeout(function(){e.afterWrite.call(e,t)},e.processTimeout):e.afterWrite(t)},afterWrite:function(t){var e;if(e=t){for(;e.firstChild;)e.removeChild(e.firstChild);(this.div=e).style.overflow="hidden",e.style.textAlign="left",t=this.chartDiv;var i=this.legendDiv,s=this.legend,a=i.style,o=t.style;this.measure(),this.previousHeight=this.divRealHeight,this.previousWidth=this.divRealWidth;var n,r=document.createElement("div");if((n=r.style).position="relative",(this.containerDiv=r).className=this.classNamePrefix+"-main-div",t.className=this.classNamePrefix+"-chart-div",e.appendChild(r),(e=this.exportConfig)&&c.AmExport&&!this.AmExport&&(this.AmExport=new c.AmExport(this,e)),this.amExport&&c.AmExport&&(this.AmExport=c.extend(this.amExport,new c.AmExport(this),!0)),this.AmExport&&this.AmExport.init&&this.AmExport.init(),s){if((s=this.addLegend(s,s.divId)).enabled)switch(a.left=null,a.top=null,a.right=null,o.left=null,o.right=null,o.top=null,a.position="relative",o.position="relative",n.width="100%",n.height="100%",s.position){case"bottom":r.appendChild(t),r.appendChild(i);break;case"top":r.appendChild(i),r.appendChild(t);break;case"absolute":a.position="absolute",o.position="absolute",void 0!==s.left&&(a.left=s.left+"px"),void 0!==s.right&&(a.right=s.right+"px"),void 0!==s.top&&(a.top=s.top+"px"),void 0!==s.bottom&&(a.bottom=s.bottom+"px"),s.marginLeft=0,s.marginRight=0,r.appendChild(t),r.appendChild(i);break;case"right":a.position="relative",o.position="absolute",r.appendChild(t),r.appendChild(i);break;case"left":a.position="absolute",o.position="relative",r.appendChild(t),r.appendChild(i);break;case"outside":r.appendChild(t)}else r.appendChild(t);this.prevLegendPosition=s.position}else r.appendChild(t);this.listenersAdded||(this.addListeners(),this.listenersAdded=!0),(this.mouseWheelScrollEnabled||this.mouseWheelZoomEnabled)&&c.addWheelListeners(),this.initChart()}},createLabelsSet:function(){c.remove(this.labelsSet),this.labelsSet=this.container.set(),this.freeLabelsSet.push(this.labelsSet)},initChart:function(){this.balloon=c.processObject(this.balloon,c.AmBalloon,this.theme),window.AmCharts_path&&(this.path=window.AmCharts_path),void 0===this.path&&(this.path=c.getPath()),void 0===this.path&&(this.path="amcharts/"),this.path=c.normalizeUrl(this.path),void 0===this.pathToImages&&(this.pathToImages=this.path+"images/"),this.initHC||(c.callInitHandler(this),this.initHC=!0),c.applyLang(this.language,this);var t=this.numberFormatter;t&&(isNaN(t.precision)||(this.precision=t.precision),void 0!==t.thousandsSeparator&&(this.thousandsSeparator=t.thousandsSeparator),void 0!==t.decimalSeparator&&(this.decimalSeparator=t.decimalSeparator)),(t=this.percentFormatter)&&!isNaN(t.precision)&&(this.percentPrecision=t.precision),this.nf={precision:this.precision,thousandsSeparator:this.thousandsSeparator,decimalSeparator:this.decimalSeparator},this.pf={precision:this.percentPrecision,thousandsSeparator:this.thousandsSeparator,decimalSeparator:this.decimalSeparator},this.destroy(),(t=this.container)?(t.container.innerHTML="",t.width=this.realWidth,t.height=this.realHeight,t.addDefs(this),this.chartDiv.appendChild(t.container)):t=new c.AmDraw(this.chartDiv,this.realWidth,this.realHeight,this),this.container=t,this.extension=".png",this.svgIcons&&c.SVG&&(this.extension=".svg"),this.checkDisplay(),this.checkTransform(this.div),t.chart=this,c.VML||c.SVG?(t.handDrawn=this.handDrawn,t.handDrawScatter=this.handDrawScatter,t.handDrawThickness=this.handDrawThickness,c.remove(this.set),this.set=t.set(),c.remove(this.gridSet),this.gridSet=t.set(),c.remove(this.cursorLineSet),this.cursorLineSet=t.set(),c.remove(this.graphsBehindSet),this.graphsBehindSet=t.set(),c.remove(this.bulletBehindSet),this.bulletBehindSet=t.set(),c.remove(this.columnSet),this.columnSet=t.set(),c.remove(this.graphsSet),this.graphsSet=t.set(),c.remove(this.trendLinesSet),this.trendLinesSet=t.set(),c.remove(this.axesSet),this.axesSet=t.set(),c.remove(this.cursorSet),this.cursorSet=t.set(),c.remove(this.scrollbarsSet),this.scrollbarsSet=t.set(),c.remove(this.bulletSet),this.bulletSet=t.set(),c.remove(this.freeLabelsSet),this.freeLabelsSet=t.set(),c.remove(this.axesLabelsSet),this.axesLabelsSet=t.set(),c.remove(this.balloonsSet),this.balloonsSet=t.set(),c.remove(this.plotBalloonsSet),this.plotBalloonsSet=t.set(),c.remove(this.zoomButtonSet),this.zoomButtonSet=t.set(),c.remove(this.zbSet),this.zbSet=null,c.remove(this.linkSet),this.linkSet=t.set()):this.fire({type:"failed",chart:this})},premeasure:function(){var t=this.div;if(t){try{this.boundingRect=this.chartDiv.getBoundingClientRect()}catch(t){}var e=t.offsetWidth,i=t.offsetHeight;t.clientHeight&&(e=t.clientWidth,i=t.clientHeight),e==this.mw&&i==this.mh||(this.mw=e,this.mh=i,this.measure())}},measure:function(){if(a=this.div){var t=this.chartDiv,e=a.offsetWidth,i=a.offsetHeight,s=this.container;a.clientHeight&&(e=a.clientWidth,i=a.clientHeight),i=Math.round(i),e=Math.round(e);var a=Math.round(c.toCoordinate(this.width,e)),o=Math.round(c.toCoordinate(this.height,i));(e!=this.previousWidth||i!=this.previousHeight)&&0<a&&0<o&&(t.style.width=a+"px",t.style.height=o+"px",t.style.padding=0,s&&s.setSize(a,o),this.balloon=c.processObject(this.balloon,c.AmBalloon,this.theme)),this.balloon&&this.balloon.setBounds&&this.balloon.setBounds(2,2,a-2,o),this.updateWidth(),(this.balloon.chart=this).realWidth=a,this.realHeight=o,this.divRealWidth=e,this.divRealHeight=i}},checkDisplay:function(){if(this.autoDisplay&&this.container){var t=c.rect(this.container,10,10),e=t.getBBox();0===e.width&&0===e.height&&(this.divRealHeight=this.divRealWidth=this.realHeight=this.realWidth=0,this.previousWidth=this.previousHeight=NaN),t.remove()}},checkTransform:function(t){if(this.autoTransform&&window.getComputedStyle&&t){if(t.style&&(e=window.getComputedStyle(t,null))&&(e=e.getPropertyValue("-webkit-transform")||e.getPropertyValue("-moz-transform")||e.getPropertyValue("-ms-transform")||e.getPropertyValue("-o-transform")||e.getPropertyValue("transform"))&&"none"!==e){var e=(i=e.split("(")[1].split(")")[0].split(","))[0],i=i[1];e=Math.sqrt(e*e+i*i),isNaN(e)||(this.cssScale*=e)}t.parentNode&&this.checkTransform(t.parentNode)}},destroy:function(){this.chartDiv.innerHTML="",this.clearTimeOuts(),this.legend&&this.legend.destroy()},clearTimeOuts:function(){var t,e=this.timeOuts;if(e)for(t=0;t<e.length;t++)clearTimeout(e[t]);this.timeOuts=[]},clear:function(t){try{document.removeEventListener("touchstart",this.docfn1,!0),document.removeEventListener("touchend",this.docfn2,!0)}catch(t){}if(c.callMethod("clear",[this.chartScrollbar,this.scrollbarV,this.scrollbarH,this.chartCursor]),this.chartCursor=this.scrollbarH=this.scrollbarV=this.chartScrollbar=null,this.clearTimeOuts(),this.container&&(this.container.remove(this.chartDiv),this.container.remove(this.legendDiv)),t||c.removeChart(this),t=this.div)for(;t.firstChild;)t.removeChild(t.firstChild);this.legend&&this.legend.destroy(),this.AmExport&&this.AmExport.clear&&this.AmExport.clear()},setMouseCursor:function(t){"auto"==t&&c.isNN&&(t="default"),this.chartDiv.style.cursor=t,this.legendDiv.style.cursor=t},redrawLabels:function(){this.labels=[];var t,e=this.allLabels;for(this.createLabelsSet(),t=0;t<e.length;t++)this.drawLabel(e[t])},drawLabel:function(t){var e=this;if(e.container&&!1!==t.enabled){var i=(t=c.processObject(t,c.Label,e.theme)).y,s=t.text,a=t.align,o=t.size,n=t.color,r=t.rotation,h=t.alpha,l=t.bold,d=c.toCoordinate(t.x,e.realWidth);d||(d=0),(i=c.toCoordinate(i,e.realHeight))||(i=0),void 0===n&&(n=e.color),isNaN(o)&&(o=e.fontSize),a||(a="start"),"left"==a&&(a="start"),"right"==a&&(a="end"),"center"==a&&(a="middle",r?i=e.realHeight-i+i/2:d=e.realWidth/2-d),void 0===h&&(h=1),void 0===r&&(r=0),i+=o/2,(s=c.text(e.container,s,n,e.fontFamily,o,a,l,h)).translate(d,i),void 0!==t.tabIndex&&s.setAttr("tabindex",t.tabIndex),c.setCN(e,s,"label"),t.id&&c.setCN(e,s,"label-"+t.id),0!==r&&s.rotate(r),t.url?(s.setAttr("cursor","pointer"),s.click(function(){c.getURL(t.url,e.urlTarget)})):s.node.style.pointerEvents="none",e.labelsSet.push(s),e.labels.push(s)}},addLabel:function(t,e,i,s,a,o,n,r,h,l){t={x:t,y:e,text:i,align:s,size:a,color:o,alpha:r,rotation:n,bold:h,url:l,enabled:!0},this.container&&this.drawLabel(t),this.allLabels.push(t)},clearLabels:function(){var t,e=this.labels;for(t=e.length-1;0<=t;t--)e[t].remove();this.labels=[],this.allLabels=[]},updateHeight:function(){var t=this.divRealHeight;if(e=this.legend){var e,i=this.legendDiv.offsetHeight;"top"!=(e=e.position)&&"bottom"!=e||(((t-=i)<0||isNaN(t))&&(t=0),this.chartDiv.style.height=t+"px")}return t},updateWidth:function(){var t=this.divRealWidth,e=this.divRealHeight,i=this.legend;if(i){var s=(o=this.legendDiv).offsetWidth;isNaN(i.width)||(s=i.width),i.ieW&&(s=i.ieW);var a=o.offsetHeight,o=o.style,n=this.chartDiv.style,r=i.position;"right"!=r&&"left"!=r||void 0!==i.divId||(((t-=s)<0||isNaN(t))&&(t=0),n.width=t+"px",this.balloon&&this.balloon.setBounds&&this.balloon.setBounds(2,2,t-2,this.realHeight),"left"==r?(n.left=s+"px",o.left="0px"):(n.left="0px",o.left=t+"px"),a<e&&(o.top=(e-a)/2+"px"))}return t},getTitleHeight:function(){return this.drawTitles(!0),this.titleHeight},addTitle:function(t,e,i,s,a){return isNaN(e)&&(e=this.fontSize+2),t={text:t,size:e,color:i,alpha:s,bold:a,enabled:!0},this.titles.push(t),t},handleWheel:function(t){var e=0;t||(t=window.event),t.wheelDelta?e=t.wheelDelta/120:t.detail&&(e=-t.detail/3),e&&this.handleWheelReal(e,t.shiftKey),t.preventDefault&&t.preventDefault()},handleWheelReal:function(){},handleDocTouchStart:function(){this.handleMouseMove(),this.tmx=this.mouseX,this.tmy=this.mouseY,this.touchStartTime=(new Date).getTime()},handleDocTouchEnd:function(){-.5<this.tmx&&this.tmx<this.divRealWidth+1&&0<this.tmy&&this.tmy<this.divRealHeight?(this.handleMouseMove(),Math.abs(this.mouseX-this.tmx)<4&&Math.abs(this.mouseY-this.tmy)<4?(this.tapped=!0,this.panRequired&&this.panEventsEnabled&&this.chartDiv&&(this.chartDiv.style.msTouchAction="none",this.chartDiv.style.touchAction="none")):this.mouseIsOver||this.resetTouchStyle()):(this.tapped=!1,this.resetTouchStyle())},resetTouchStyle:function(){this.panEventsEnabled&&this.chartDiv&&(this.chartDiv.style.msTouchAction="auto",this.chartDiv.style.touchAction="auto")},checkTouchDuration:function(t){var e=this,i=(new Date).getTime();if(t)if(t.touches)e.isTouchEvent=!0;else if(!e.isTouchEvent)return!0;if(i-e.touchStartTime>e.touchClickDuration)return!0;setTimeout(function(){e.resetTouchDuration()},300)},resetTouchDuration:function(){this.isTouchEvent=!1},checkTouchMoved:function(){if(4<Math.abs(this.mouseX-this.tmx)||4<Math.abs(this.mouseY-this.tmy))return!0},addListeners:function(){var e=this,t=e.chartDiv;document.addEventListener?("ontouchstart"in document.documentElement&&(t.addEventListener("touchstart",function(t){e.handleTouchStart.call(e,t)},!0),t.addEventListener("touchmove",function(t){e.handleMouseMove.call(e,t)},!0),t.addEventListener("touchend",function(t){e.handleTouchEnd.call(e,t)},!0),e.docfn1=function(t){e.handleDocTouchStart.call(e,t)},e.docfn2=function(t){e.handleDocTouchEnd.call(e,t)},document.addEventListener("touchstart",e.docfn1,!0),document.addEventListener("touchend",e.docfn2,!0)),t.addEventListener("mousedown",function(t){e.mouseIsOver=!0,e.handleMouseMove.call(e,t),e.handleMouseDown.call(e,t),e.handleDocTouchStart.call(e,t)},!0),t.addEventListener("mouseover",function(t){e.handleMouseOver.call(e,t)},!0),t.addEventListener("mouseout",function(t){e.handleMouseOut.call(e,t)},!0),t.addEventListener("mouseup",function(t){e.handleDocTouchEnd.call(e,t)},!0)):(t.attachEvent("onmousedown",function(t){e.handleMouseDown.call(e,t)}),t.attachEvent("onmouseover",function(t){e.handleMouseOver.call(e,t)}),t.attachEvent("onmouseout",function(t){e.handleMouseOut.call(e,t)}))},dispDUpd:function(){this.skipEvents||(this.dispatchDataUpdated&&(this.dispatchDataUpdated=!1,this.fire({type:"dataUpdated",chart:this})),this.chartCreated||(this.chartCreated=!0,this.fire({type:"init",chart:this})),this.chartRendered||(this.fire({type:"rendered",chart:this}),this.chartRendered=!0),this.fire({type:"drawn",chart:this})),this.skipEvents=!1},validateSize:function(){var t=this;if(t.premeasure(),t.checkDisplay(),t.cssScale=1,t.cssAngle=0,t.checkTransform(t.div),t.divRealWidth!=t.previousWidth||t.divRealHeight!=t.previousHeight){var e=t.legend;if(0<t.realWidth&&0<t.realHeight){if(t.sizeChanged=!0,e){t.legendInitTO&&clearTimeout(t.legendInitTO);var i=setTimeout(function(){e.invalidateSize()},10);t.timeOuts.push(i),t.legendInitTO=i}t.marginsUpdated=!1,clearTimeout(t.initTO),i=setTimeout(function(){t.initChart()},10),t.timeOuts.push(i),t.initTO=i}t.renderFix(),e&&e.renderFix&&e.renderFix(),t.positionCred(),clearTimeout(t.resizedTO),t.resizedTO=setTimeout(function(){t.fire({type:"resized",chart:t})},10),t.previousHeight=t.divRealHeight,t.previousWidth=t.divRealWidth}},invalidateSize:function(){this.previousHeight=this.previousWidth=NaN,this.invalidateSizeReal()},invalidateSizeReal:function(){var t=this;t.marginsUpdated=!1,clearTimeout(t.validateTO);var e=setTimeout(function(){t.validateSize()},5);t.timeOuts.push(e),t.validateTO=e},validateData:function(t){this.chartCreated&&(this.dataChanged=!0,this.marginsUpdated=!1,this.initChart(t))},validateNow:function(t,e){this.initTO&&clearTimeout(this.initTO),t&&(this.dataChanged=!0,this.marginsUpdated=!1),this.skipEvents=e,this.chartRendered=!1;var i=this.legend;i&&i.position!=this.prevLegendPosition&&(this.previousWidth=this.mw=0,i.invalidateSize&&(i.invalidateSize(),this.validateSize())),this.write(this.div)},showItem:function(t){t.hidden=!1,this.initChart()},hideItem:function(t){t.hidden=!0,this.initChart()},hideBalloon:function(){var t=this;clearTimeout(t.hoverInt),clearTimeout(t.balloonTO),t.hoverInt=setTimeout(function(){t.hideBalloonReal.call(t)},t.hideBalloonTime)},cleanChart:function(){},hideBalloonReal:function(){var t=this.balloon;t&&t.hide&&t.hide()},showBalloon:function(t,e,i,s,a){var o=this;clearTimeout(o.balloonTO),clearTimeout(o.hoverInt),o.balloonTO=setTimeout(function(){o.showBalloonReal.call(o,t,e,i,s,a)},1)},showBalloonReal:function(t,e,i,s,a){this.handleMouseMove();var o=this.balloon;o.enabled&&(o.followCursor(!1),o.changeColor(e),!i||o.fixedPosition?(o.setPosition(s,a),isNaN(s)||isNaN(a)?o.followCursor(!0):o.followCursor(!1)):o.followCursor(!0),t&&o.showBalloon(t))},handleMouseOver:function(){this.outTO&&clearTimeout(this.outTO),c.resetMouseOver(),this.mouseIsOver=!0},handleMouseOut:function(){var t=this;c.resetMouseOver(),t.outTO&&clearTimeout(t.outTO),t.outTO=setTimeout(function(){t.handleMouseOutReal()},10)},handleMouseOutReal:function(){this.mouseIsOver=!1},handleMouseMove:function(t){var e,i,s,a;if(t||(t=window.event),this.mouse2Y=this.mouse2X=NaN,t){if(t.touches){var o=t.touches.item(1);if(o&&this.panEventsEnabled&&this.boundingRect&&(s=o.clientX-this.boundingRect.left,a=o.clientY-this.boundingRect.top),!(t=t.touches.item(0)))return}else this.wasTouched=!1;this.boundingRect&&t.clientX&&(e=t.clientX-this.boundingRect.left,i=t.clientY-this.boundingRect.top),isNaN(s)?this.mouseX=e:(this.mouseX=Math.min(e,s),this.mouse2X=Math.max(e,s)),isNaN(a)?this.mouseY=i:(this.mouseY=Math.min(i,a),this.mouse2Y=Math.max(i,a)),this.autoTransform&&(this.mouseX/=this.cssScale,this.mouseY/=this.cssScale)}},handleTouchStart:function(t){this.hideBalloonReal(),t&&(t.touches&&this.tapToActivate&&!this.tapped||!this.panRequired)||(this.handleMouseMove(t),this.handleMouseDown(t))},handleTouchEnd:function(t){this.wasTouched=!0,this.handleMouseMove(t),c.resetMouseOver(),this.handleReleaseOutside(t)},handleReleaseOutside:function(){this.handleDocTouchEnd.call(this)},handleMouseDown:function(t){c.resetMouseOver(),this.mouseIsOver=!0,t&&t.preventDefault&&(this.panEventsEnabled?t.preventDefault():t.touches||t.preventDefault())},addLegend:function(t,e){var i;return(t=c.processObject(t,c.AmLegend,this.theme)).divId=e,t.ieW=0,i="object"!=typeof e&&e?document.getElementById(e):e,(this.legend=t).chart=this,i?(t.div=i,t.position="outside",t.autoMargins=!1):t.div=this.legendDiv,t},removeLegend:function(){this.legend=void 0,this.previousWidth=0,this.legendDiv.innerHTML=""},handleResize:function(){(c.isPercents(this.width)||c.isPercents(this.height))&&this.invalidateSizeReal(),this.renderFix()},renderFix:function(){if(!c.VML){var t=this.container;t&&t.renderFix()}},getSVG:function(){if(c.hasSVG)return this.container},animate:function(t,e,i,s,a,o,n){return t["an_"+e]&&c.removeFromArray(this.animations,t["an_"+e]),i={obj:t,frame:0,attribute:e,from:i,to:s,time:a,effect:o,suffix:n},t["an_"+e]=i,this.animations.push(i),i},setLegendData:function(t){var e=this.legend;e&&e.setData(t)},stopAnim:function(t){c.removeFromArray(this.animations,t)},updateAnimations:function(){var t;if(this.container&&this.container.update(),this.animations)for(t=this.animations.length-1;0<=t;t--){var e=this.animations[t],i=c.updateRate*e.time,s=e.frame+1,a=e.obj,o=e.attribute;if(s<=i){e.frame++;var n=Number(e.from),r=Number(e.to)-n;i=c[e.effect](0,s,n,r,i),0===r?(this.animations.splice(t,1),a.node.style[o]=Number(e.to)+e.suffix):a.node.style[o]=i+e.suffix}else a.node.style[o]=Number(e.to)+e.suffix,a.animationFinished=!0,this.animations.splice(t,1)}},update:function(){this.updateAnimations();var t=this.animatable;if(0<t.length){for(var e=!0,i=t.length-1;0<=i;i--){var s=t[i];s&&(s.animationFinished?t.splice(i,1):e=!1)}e&&(this.fire({type:"animationFinished",chart:this}),this.animatable=[])}},inIframe:function(){try{return window.self!==window.top}catch(t){return!0}},positionCred:function(){if(s=this.amLink){var t=this.creditsPosition,e=s.style,i=s.offsetWidth,s=s.offsetHeight,a=0,o=0,n=this.realWidth,r=this.realHeight;"serial"!=(h=this.type)&&"xy"!=h&&"gantt"!=h||(a=this.marginLeftReal,o=this.marginTopReal,n=a+this.plotAreaWidth,r=o+this.plotAreaHeight);var h=5+a,l=o+5;"bottom-left"==t&&(h=5+a,l=r-s-3),"bottom-right"==t&&(h=n-i-5,l=r-s-3),"top-right"==t&&(h=n-i-5,l=o+5),e.left=h+"px",e.top=l+"px"}}}),c.Slice=c.Class({construct:function(){}}),c.SerialDataItem=c.Class({construct:function(){}}),c.GraphDataItem=c.Class({construct:function(){}}),c.Guide=c.Class({construct:function(t){this.cname="Guide",c.applyTheme(this,t,this.cname)}}),c.Title=c.Class({construct:function(t){this.cname="Title",c.applyTheme(this,t,this.cname)}}),c.Label=c.Class({construct:function(t){this.cname="Label",c.applyTheme(this,t,this.cname)}})}(),function(){var R=window.AmCharts;R.AmBalloon=R.Class({construct:function(t){this.cname="AmBalloon",this.enabled=!0,this.fillColor="#FFFFFF",this.fillAlpha=.8,this.borderThickness=2,this.borderColor="#FFFFFF",this.borderAlpha=1,this.cornerRadius=0,this.maxWidth=220,this.horizontalPadding=8,this.verticalPadding=4,this.pointerWidth=6,this.pointerOrientation="V",this.color="#000000",this.adjustBorderColor=!0,this.show=this.follow=this.showBullet=!1,this.bulletSize=3,this.shadowAlpha=.4,this.shadowColor="#000000",this.fadeOutDuration=this.animationDuration=.3,this.fixedPosition=!0,this.offsetY=6,this.offsetX=1,this.textAlign="center",this.disableMouseEvents=!0,this.deltaSignX=this.deltaSignY=1,R.isModern||(this.offsetY*=1.5),this.sdy=this.sdx=0,R.applyTheme(this,t,this.cname)},draw:function(){var t=this.pointToX,e=this.pointToY;R.isModern||(this.drop=!1);var i=this.chart;if(R.VML&&(this.fadeOutDuration=0),this.xAnim&&i.stopAnim(this.xAnim),this.yAnim&&i.stopAnim(this.yAnim),this.sdy=this.sdx=0,!isNaN(t)){var s=this.follow,a=i.container,o=this.set;if(R.remove(o),this.removeDiv(),(o=a.set()).node.style.pointerEvents="none",this.set=o,this.mainSet?(this.mainSet.push(this.set),this.sdx=this.mainSet.x,this.sdy=this.mainSet.y):i.balloonsSet.push(o),this.show){var n=this.l,r=this.t,h=this.r,l=this.b,d=this.balloonColor,c=this.fillColor,u=this.borderColor,m=c;null!=d&&(this.adjustBorderColor?m=u=d:c=d);var p=this.horizontalPadding,g=this.verticalPadding,f=this.pointerWidth,v=this.pointerOrientation,b=this.cornerRadius,N=i.fontFamily;null==(L=this.fontSize)&&(L=i.fontSize),d=document.createElement("div");var C=i.classNamePrefix;d.className=C+"-balloon-div",this.className&&(d.className=d.className+" "+C+"-balloon-div-"+this.className),C=d.style,this.disableMouseEvents&&(C.pointerEvents="none"),C.position="absolute";var w=this.minWidth,M=document.createElement("div");d.appendChild(M);var S=M.style;isNaN(w)||(S.minWidth=w-2*p+"px"),S.textAlign=this.textAlign,S.maxWidth=this.maxWidth+"px",S.fontSize=L+"px",S.color=this.color,S.fontFamily=N,M.innerHTML=this.text,i.chartDiv.appendChild(d),S=(this.textDiv=d).offsetWidth;var y=d.offsetHeight;d.clientHeight&&(S=d.clientWidth,y=d.clientHeight),N=y+2*g,M=S+2*p,!isNaN(w)&&M<w&&(M=w),window.opera&&(N+=2);var T=!1,L=this.offsetY;i.handDrawn&&(L+=i.handDrawScatter+2),"H"!=v?(w=t-M/2,e<r+N+10&&"down"!=v?(T=!0,s&&(e+=L),L=e+f,this.deltaSignY=-1):(s&&(e-=L),L=e-N-f,this.deltaSignY=1)):(N<2*f&&(f=N/2),L=e-N/2,t<n+(h-n)/2?(w=t+f,this.deltaSignX=-1):(w=t-M-f,this.deltaSignX=1)),l<=L+N&&(L=l-N),L<r&&(L=r),w<n&&(w=n),h<w+M&&(w=h-M),r=L+g,l=w+p;var x,A=this.shadowAlpha,O=this.shadowColor,z=(p=this.borderThickness,this.bulletSize),k=(g=this.fillAlpha,this.borderAlpha);this.showBullet&&(x=R.circle(a,z,m,g),o.push(x)),this.drop?(n=M/1.6,h=0,"V"==v&&(v="down"),"H"==v&&(v="left"),"down"==v&&(w=t+1,L=e-n-n/3),"up"==v&&(h=180,w=t+1,L=e+n+n/3),"left"==v&&(h=270,w=t+n+n/3+2,L=e),"right"==v&&(h=90,w=t-n-n/3+2,L=e),r=L-y/2+1,l=w-S/2-1,c=R.drop(a,n,h,c,g,p,u,k)):0<b||0===f?(0<A&&(t=R.rect(a,M,N,c,0,p+1,O,A,b),R.isModern?t.translate(1,1):t.translate(4,4),o.push(t)),c=R.rect(a,M,N,c,g,p,u,k,b)):(m=[],b=[],"H"!=v?(M-f<(n=t-w)&&(n=M-f),n<f&&(n=f),m=[0,n-f,t-w,n+f,M,M,0,0],b=T?[0,0,e-L,0,0,N,N,0]:[N,N,e-L,N,N,0,0,N]):(N-f<(v=e-L)&&(v=N-f),v<f&&(v=f),b=[0,v-f,e-L,v+f,N,N,0,0],m=t<n+(h-n)/2?[0,0,w<t?0:t-w,0,0,M,M,0]:[M,M,t<w+M?M:t-w,M,M,0,0,M]),0<A&&((t=R.polygon(a,m,b,c,0,p,O,A)).translate(1,1),o.push(t)),c=R.polygon(a,m,b,c,g,p,u,k)),this.bg=c,o.push(c),c.toFront(),R.setCN(i,c,"balloon-bg"),this.className&&R.setCN(i,c,"balloon-bg-"+this.className),a=1*this.deltaSignX,l+=this.sdx,r+=this.sdy,C.left=l+"px",C.top=r+"px",o.translate(w-a,L,1,!0),c=c.getBBox(),this.bottom=L+N+1,this.yPos=c.y+L,x&&x.translate(this.pointToX-w+a,e-L),e=this.animationDuration,0<this.animationDuration&&!s&&!isNaN(this.prevX)&&(o.translate(this.prevX,this.prevY,NaN,!0),o.animate({translate:w-a+","+L},e,"easeOutSine"),d&&(C.left=this.prevTX+"px",C.top=this.prevTY+"px",this.xAnim=i.animate({node:d},"left",this.prevTX,l,e,"easeOutSine","px"),this.yAnim=i.animate({node:d},"top",this.prevTY,r,e,"easeOutSine","px"))),this.prevX=w-a,this.prevY=L,this.prevTX=l,this.prevTY=r}}},fixPrevious:function(){this.rPrevX=this.prevX,this.rPrevY=this.prevY,this.rPrevTX=this.prevTX,this.rPrevTY=this.prevTY},restorePrevious:function(){this.prevX=this.rPrevX,this.prevY=this.rPrevY,this.prevTX=this.rPrevTX,this.prevTY=this.rPrevTY},followMouse:function(){if(this.follow&&this.show){var t=this.chart.mouseX-this.offsetX*this.deltaSignX-this.sdx,e=this.chart.mouseY-this.sdy;if(this.pointToX=t,this.pointToY=e,t!=this.previousX||e!=this.previousY)if(this.previousX=t,this.previousY=e,0===this.cornerRadius)this.draw();else{var i=this.set;if(i){var s=i.getBBox(),a=(t-=s.width/2,e-s.height-10);t<this.l&&(t=this.l),t>this.r-s.width&&(t=this.r-s.width),a<this.t&&(a=e+10),i.translate(t,a),(e=this.textDiv.style).left=t+this.horizontalPadding+"px",e.top=a+this.verticalPadding+"px"}}}},changeColor:function(t){this.balloonColor=t},setBounds:function(t,e,i,s){this.l=t,this.t=e,this.r=i,this.b=s,this.destroyTO&&clearTimeout(this.destroyTO)},showBalloon:function(t){(this.text!=t||this.positionChanged)&&(this.text=t,this.isHiding=!1,this.show=!0,this.destroyTO&&clearTimeout(this.destroyTO),t=this.chart,this.fadeAnim1&&t.stopAnim(this.fadeAnim1),this.fadeAnim2&&t.stopAnim(this.fadeAnim2),this.draw(),this.positionChanged=!1)},hide:function(t){var e=this;e.text=void 0,isNaN(t)&&(t=e.fadeOutDuration);var i=e.chart;if(0<t&&!e.isHiding){e.isHiding=!0,e.destroyTO&&clearTimeout(e.destroyTO),e.destroyTO=setTimeout(function(){e.destroy.call(e)},1e3*t),e.follow=!1,e.show=!1;var s=e.set;s&&(s.setAttr("opacity",e.fillAlpha),e.fadeAnim1=s.animate({opacity:0},t,"easeInSine")),e.textDiv&&(e.fadeAnim2=i.animate({node:e.textDiv},"opacity",1,0,t,"easeInSine",""))}else e.show=!1,e.follow=!1,e.destroy()},setPosition:function(t,e){t==this.pointToX&&e==this.pointToY||(this.previousX=this.pointToX,this.previousY=this.pointToY,this.pointToX=t,this.pointToY=e,this.positionChanged=!0)},followCursor:function(t){var e=this;e.follow=t,clearInterval(e.interval);var i=e.chart.mouseX-e.sdx,s=e.chart.mouseY-e.sdy;!isNaN(i)&&t&&(e.pointToX=i-e.offsetX*e.deltaSignX,e.pointToY=s,e.followMouse(),e.interval=setInterval(function(){e.followMouse.call(e)},40))},removeDiv:function(){if(this.textDiv){var t=this.textDiv.parentNode;t&&t.removeChild(this.textDiv)}},destroy:function(){clearInterval(this.interval),R.remove(this.set),this.removeDiv(),this.set=null}})}(),function(){var R=window.AmCharts;R.circle=function(t,e,i,s,a,o,n,r,h){return e<=0&&(e=.001),null!=a&&0!==a||(a=.01),void 0===o&&(o="#000000"),void 0===n&&(n=0),s={fill:i,stroke:o,"fill-opacity":s,"stroke-width":a,"stroke-opacity":n},t=isNaN(h)?t.circle(0,0,e).attr(s):t.ellipse(0,0,e,h).attr(s),r&&t.gradient("radialGradient",[i,R.adjustLuminosity(i,-.6)]),t},R.text=function(t,e,i,s,a,o,n,r){return o||(o="middle"),"right"==o&&(o="end"),"left"==o&&(o="start"),isNaN(r)&&(r=1),void 0!==e&&(e=String(e),R.isIE&&!R.isModern&&(e=(e=e.replace("&amp;","&")).replace("&","&amp;"))),i={fill:i,"font-family":s,"font-size":a+"px",opacity:r},!0===n&&(i["font-weight"]="bold"),i["text-anchor"]=o,t.text(e,i)},R.polygon=function(t,e,i,s,a,o,n,r,h,l,d){isNaN(o)&&(o=.01),isNaN(r)&&(r=a);var c=s,u=!1;for("object"==typeof c&&1<c.length&&(u=!0,c=c[0]),void 0===n&&(n=c),a={fill:c,stroke:n,"fill-opacity":a,"stroke-width":o,"stroke-opacity":r},void 0!==d&&0<d&&(a["stroke-dasharray"]=d),d=R.dx,o=R.dy,t.handDrawn&&(e=(i=R.makeHD(e,i,t.handDrawScatter))[0],i=i[1]),n=Math.round,l&&(n=Number),r="M"+(n(e[0])+d)+","+(n(i[0])+o),c=1;c<e.length;c++)l&&(e[c]=R.roundTo(e[c],5),i[c]=R.roundTo(i[c],5)),r+=" L"+(n(e[c])+d)+","+(n(i[c])+o);return t=t.path(r+" Z").attr(a),u&&t.gradient("linearGradient",s,h),t},R.rect=function(t,e,i,s,a,o,n,r,h,l,d){if(isNaN(e)||isNaN(i))return t.set();isNaN(o)&&(o=0),void 0===h&&(h=0),void 0===l&&(l=270),isNaN(a)&&(a=0);var c=s,u=!1;"object"==typeof c&&(c=c[0],u=!0),void 0===n&&(n=c),void 0===r&&(r=a),e=Math.round(e),i=Math.round(i);var m=0,p=0;return e<0&&(m=-(e=Math.abs(e))),i<0&&(p=-(i=Math.abs(i))),m+=R.dx,p+=R.dy,a={fill:c,stroke:n,"fill-opacity":a,"stroke-opacity":r},void 0!==d&&0<d&&(a["stroke-dasharray"]=d),t=t.rect(m,p,e,i,h,o).attr(a),u&&t.gradient("linearGradient",s,l),t},R.bullet=function(t,e,i,s,a,o,n,r,h,l,d,c,u){var m;switch("circle"==e&&(e="round"),e){case"round":m=R.circle(t,i/2,s,a,o,n,r);break;case"square":m=R.polygon(t,[-i/2,i/2,i/2,-i/2],[i/2,i/2,-i/2,-i/2],s,a,o,n,r,l-180,void 0,u);break;case"rectangle":m=R.polygon(t,[-i,i,i,-i],[i/2,i/2,-i/2,-i/2],s,a,o,n,r,l-180,void 0,u);break;case"diamond":m=R.polygon(t,[-i/2,0,i/2,0],[0,-i/2,0,i/2],s,a,o,n,r);break;case"triangleUp":m=R.triangle(t,i,0,s,a,o,n,r);break;case"triangleDown":m=R.triangle(t,i,180,s,a,o,n,r);break;case"triangleLeft":m=R.triangle(t,i,270,s,a,o,n,r);break;case"triangleRight":m=R.triangle(t,i,90,s,a,o,n,r);break;case"bubble":m=R.circle(t,i/2,s,a,o,n,r,!0);break;case"line":m=R.line(t,[-i/2,i/2],[0,0],s,a,o,n,r);break;case"yError":(m=t.set()).push(R.line(t,[0,0],[-i/2,i/2],s,a,o)),m.push(R.line(t,[-h,h],[-i/2,-i/2],s,a,o)),m.push(R.line(t,[-h,h],[i/2,i/2],s,a,o));break;case"xError":(m=t.set()).push(R.line(t,[-i/2,i/2],[0,0],s,a,o)),m.push(R.line(t,[-i/2,-i/2],[-h,h],s,a,o)),m.push(R.line(t,[i/2,i/2],[-h,h],s,a,o))}return m&&m.pattern(d,NaN,c),m},R.triangle=function(t,e,i,s,a,o,n,r){var h;return void 0!==o&&0!==o||(o=1),void 0===n&&(n="#000"),void 0===r&&(r=0),s={fill:s,stroke:n,"fill-opacity":a,"stroke-width":o,"stroke-opacity":r},e/=2,0===i&&(h=" M"+-e+","+e+" L0,"+-e+" L"+e+","+e+" Z"),180==i&&(h=" M"+-e+","+-e+" L0,"+e+" L"+e+","+-e+" Z"),90==i&&(h=" M"+-e+","+-e+" L"+e+",0 L"+-e+","+e+" Z"),270==i&&(h=" M"+-e+",0 L"+e+","+e+" L"+e+","+-e+" Z"),t.path(h).attr(s)},R.line=function(t,e,i,s,a,o,n,r,h,l,d){if(t.handDrawn&&!d)return R.handDrawnLine(t,e,i,s,a,o,n,r,h,l,d);for(o={fill:"none","stroke-width":o},void 0!==n&&0<n&&(o["stroke-dasharray"]=n),isNaN(a)||(o["stroke-opacity"]=a),s&&(o.stroke=s),s=Math.round,l&&(s=Number,e[0]=R.roundTo(e[0],5),i[0]=R.roundTo(i[0],5)),l=R.dx,a=R.dy,n="M"+(s(e[0])+l)+","+(s(i[0])+a),r=1;r<e.length;r++)e[r]=R.roundTo(e[r],5),i[r]=R.roundTo(i[r],5),n+=" L"+(s(e[r])+l)+","+(s(i[r])+a);return R.VML?t.path(n,void 0,!0).attr(o):(h&&(n+=" M0,0 L0,0"),t.path(n).attr(o))},R.makeHD=function(t,e,i){for(var s=[],a=[],o=1;o<t.length;o++)for(var n=Number(t[o-1]),r=Number(e[o-1]),h=Number(t[o]),l=Number(e[o]),d=Math.round(Math.sqrt(Math.pow(h-n,2)+Math.pow(l-r,2))/50)+1,c=(h=(h-n)/d,l=(l-r)/d,0);c<=d;c++){var u=r+c*l+Math.random()*i;s.push(n+c*h+Math.random()*i),a.push(u)}return[s,a]},R.handDrawnLine=function(t,e,i,s,a,o,n,r,h,l){var d,c=t.set();for(d=1;d<e.length;d++)for(var u=[e[d-1],e[d]],m=[i[d-1],i[d]],p=(u=(m=R.makeHD(u,m,t.handDrawScatter))[0],m=m[1],1);p<u.length;p++)c.push(R.line(t,[u[p-1],u[p]],[m[p-1],m[p]],s,a,o+Math.random()*t.handDrawThickness-t.handDrawThickness/2,n,r,h,l,!0));return c},R.doNothing=function(t){return t},R.drop=function(t,e,i,s,a,o,n,r){var h=1/180*Math.PI,l=i-20,d=Math.sin(l*h)*e,c=Math.cos(l*h)*e,u=.8*e,m=-e/3,p=e/3;return 0===i&&(m=-m,p=0),180==i&&(p=0),90==i&&(m=0),270==i&&(m=0,p=-p),i={fill:s,stroke:n,"stroke-width":o,"stroke-opacity":r,"fill-opacity":a},e="M"+d+","+c+" A"+e+","+e+",0,1,1,"+Math.sin((l+40)*h)*e+","+Math.cos((l+40)*h)*e+" A"+u+","+u+",0,0,0,"+(Math.sin((l+20)*h)*e+p)+","+(Math.cos((l+20)*h)*e+m),e+=" A"+u+","+u+",0,0,0,"+d+","+c,t.path(e,void 0,void 0,"1000,1000").attr(i)},R.wedge=function(t,e,i,s,a,o,n,r,h,l,d,c,u,m){var p=Math.round;o=p(o);var g=p((n=p(n))/o*(r=p(r))),f=R.VML;359.94<(C=359.5+o/100)&&(C=359.94),C<=a&&(a=C);var v,b,N=1/180*Math.PI,C=e+Math.sin(s*N)*r,w=i-Math.cos(s*N)*g,M=e+Math.sin(s*N)*o,S=i-Math.cos(s*N)*n,y=e+Math.sin((s+a)*N)*o,T=i-Math.cos((s+a)*N)*n,L=e+Math.sin((s+a)*N)*r,x=(N=i-Math.cos((s+a)*N)*g,{fill:R.adjustLuminosity(l.fill,-.2),"stroke-opacity":0,"fill-opacity":l["fill-opacity"]}),A=0;if(180<Math.abs(a)&&(A=1),s=t.set(),f&&(C=p(10*C),M=p(10*M),y=p(10*y),L=p(10*L),w=p(10*w),S=p(10*S),T=p(10*T),N=p(10*N),e=p(10*e),h=p(10*h),i=p(10*i),o*=10,n*=10,r*=10,g*=10,Math.abs(a)<1&&Math.abs(y-M)<=1&&Math.abs(T-S)<=1&&(v=!0)),a="",c&&(x["fill-opacity"]=0,x["stroke-opacity"]=l["stroke-opacity"]/2,x.stroke=l.stroke),0<h){b=" M"+C+","+(w+h)+" L"+M+","+(S+h),f?(v||(b+=" A"+(e-o)+","+(h+i-n)+","+(e+o)+","+(h+i+n)+","+M+","+(S+h)+","+y+","+(T+h)),b+=" L"+L+","+(N+h),0<r&&(v||(b+=" B"+(e-r)+","+(h+i-g)+","+(e+r)+","+(h+i+g)+","+L+","+(h+N)+","+C+","+(h+w)))):(b+=" A"+o+","+n+",0,"+A+",1,"+y+","+(T+h)+" L"+L+","+(N+h),0<r&&(b+=" A"+r+","+g+",0,"+A+",0,"+C+","+(w+h))),b+=" Z";var O=h;f&&(O/=10);for(var z=0;z<O;z+=10){var k=t.path(b,void 0,void 0,"1000,1000").attr(x);s.push(k),k.translate(0,-z)}b=t.path(" M"+C+","+w+" L"+C+","+(w+h)+" L"+M+","+(S+h)+" L"+M+","+S+" L"+C+","+w+" Z",void 0,void 0,"1000,1000").attr(x),h=t.path(" M"+y+","+T+" L"+y+","+(T+h)+" L"+L+","+(N+h)+" L"+L+","+N+" L"+y+","+T+" Z",void 0,void 0,"1000,1000").attr(x),s.push(b),s.push(h)}if(f?(v||(a=" A"+p(e-o)+","+p(i-n)+","+p(e+o)+","+p(i+n)+","+p(M)+","+p(S)+","+p(y)+","+p(T)),n=" M"+p(C)+","+p(w)+" L"+p(M)+","+p(S)+a+" L"+p(L)+","+p(N)):n=" M"+C+","+w+" L"+M+","+S+" A"+o+","+n+",0,"+A+",1,"+y+","+T+" L"+L+","+N,0<r&&(f?v||(n+=" B"+(e-r)+","+(i-g)+","+(e+r)+","+(i+g)+","+L+","+N+","+C+","+w):n+=" A"+r+","+g+",0,"+A+",0,"+C+","+w),t.handDrawn&&(r=R.line(t,[C,M],[w,S],l.stroke,l.thickness*Math.random()*t.handDrawThickness,l["stroke-opacity"]),s.push(r)),t=t.path(n+" Z",void 0,void 0,"1000,1000").attr(l),d){for(r=[],g=0;g<d.length;g++)r.push(R.adjustLuminosity(l.fill,d[g]));"radial"!=m||R.isModern||(r=[]),0<r.length&&t.gradient(m+"Gradient",r)}return R.isModern&&"radial"==m&&t.grad&&(t.grad.setAttribute("gradientUnits","userSpaceOnUse"),t.grad.setAttribute("r",o),t.grad.setAttribute("cx",e),t.grad.setAttribute("cy",i)),t.pattern(c,NaN,u),s.wedge=t,s.push(t),s},R.rgb2hex=function(t){return(t=t.match(/^rgba?[\s+]?\([\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?,[\s+]?(\d+)[\s+]?/i))&&4===t.length?"#"+("0"+parseInt(t[1],10).toString(16)).slice(-2)+("0"+parseInt(t[2],10).toString(16)).slice(-2)+("0"+parseInt(t[3],10).toString(16)).slice(-2):""},R.adjustLuminosity=function(t,e){t&&-1!=t.indexOf("rgb")&&(t=R.rgb2hex(t)),(t=String(t).replace(/[^0-9a-f]/gi,"")).length<6&&(t=String(t[0])+String(t[0])+String(t[1])+String(t[1])+String(t[2])+String(t[2])),e=e||0;var i,s,a="#";for(s=0;s<3;s++)i=parseInt(t.substr(2*s,2),16),a+=("00"+(i=Math.round(Math.min(Math.max(0,i+i*e),255)).toString(16))).substr(i.length);return a}}(),function(){var L=window.AmCharts;L.AmLegend=L.Class({construct:function(t){this.enabled=!0,this.cname="AmLegend",this.createEvents("rollOverMarker","rollOverItem","rollOutMarker","rollOutItem","showItem","hideItem","clickMarker","clickLabel"),this.position="bottom",this.borderColor=this.color="#000000",this.borderAlpha=0,this.markerLabelGap=5,this.verticalGap=10,this.align="left",this.horizontalGap=0,this.spacing=10,this.markerDisabledColor="#AAB3B3",this.markerType="square",this.markerSize=16,this.markerBorderThickness=this.markerBorderAlpha=1,this.marginBottom=this.marginTop=0,this.marginLeft=this.marginRight=20,this.autoMargins=!0,this.valueWidth=50,this.switchable=!0,this.switchType="x",this.switchColor="#FFFFFF",this.rollOverColor="#CC0000",this.reversedOrder=!1,this.labelText="[[title]]",this.valueText="[[value]]",this.accessibleLabel="[[title]]",this.useMarkerColorForLabels=!1,this.rollOverGraphAlpha=1,this.textClickEnabled=!1,this.equalWidths=!0,this.backgroundColor="#FFFFFF",this.backgroundAlpha=0,this.useGraphSettings=!1,this.showEntries=!0,this.labelDx=0,L.applyTheme(this,t,this.cname)},setData:function(t){this.legendData=t,this.invalidateSize()},invalidateSize:function(){this.destroy(),this.entries=[],this.valueLabels=[];var t=this.legendData;this.enabled&&(L.ifArray(t)||L.ifArray(this.data))&&this.drawLegend()},drawLegend:function(){var t=this.chart,e=this.position,i=this.width,s=t.divRealWidth,a=t.divRealHeight,o=this.div,n=this.legendData;if(this.data&&(n=this.combineLegend?this.legendData.concat(this.data):this.data),isNaN(this.fontSize)&&(this.fontSize=t.fontSize),this.maxColumnsReal=this.maxColumns,"right"==e||"left"==e)this.maxColumnsReal=1,this.autoMargins&&(this.marginLeft=this.marginRight=10);else if(this.autoMargins){this.marginRight=t.marginRight,this.marginLeft=t.marginLeft;var r=t.autoMarginOffset;"bottom"==e?(this.marginBottom=r,this.marginTop=0):(this.marginTop=r,this.marginBottom=0)}if(i=void 0!==i?L.toCoordinate(i,s):"right"!=e&&"left"!=e?t.realWidth:0<this.ieW?this.ieW:t.realWidth,"outside"==e?(i=o.offsetWidth,a=o.offsetHeight,o.clientHeight&&(i=o.clientWidth,a=o.clientHeight)):(isNaN(i)||(o.style.width=i+"px"),o.className="amChartsLegend "+t.classNamePrefix+"-legend-div"),this.divWidth=i,(e=this.container)?(e.container.innerHTML="",o.appendChild(e.container),e.width=i,e.height=a,e.setSize(i,a),e.addDefs(t)):e=new L.AmDraw(o,i,a,t),this.container=e,this.lx=0,this.ly=8,(a=this.markerSize)>this.fontSize&&(this.ly=a/2-1),0<a&&(this.lx+=a+this.markerLabelGap),this.titleWidth=0,(a=this.title)&&(a=L.text(this.container,a,this.color,t.fontFamily,this.fontSize,"start",!0),L.setCN(t,a,"legend-title"),a.translate(this.marginLeft,this.marginTop+this.verticalGap+this.ly+1),t=a.getBBox(),this.titleWidth=t.width+15,this.titleHeight=t.height+6),this.index=this.maxLabelWidth=0,this.showEntries){for(t=0;t<n.length;t++)this.createEntry(n[t]);for(t=this.index=0;t<n.length;t++)this.createValue(n[t])}this.arrangeEntries(),this.updateValues()},arrangeEntries:function(){var t=this.position,e=this.marginLeft+this.titleWidth,i=this.marginRight,s=this.marginTop,a=this.marginBottom,o=this.horizontalGap,n=this.div,r=this.divWidth,h=this.maxColumnsReal,l=this.verticalGap,d=this.spacing,c=r-i-e,u=0,m=0,p=this.container;this.set&&this.set.remove();var g=p.set();this.set=g;var f=p.set();g.push(f);var v,b,N=this.entries;for(b=0;b<N.length;b++)u<(C=(v=N[b].getBBox()).width)&&(u=C),m<(v=v.height)&&(m=v);var C=m=0,w=o,M=0,S=0;for(b=0;b<N.length;b++){var y,T=N[b];this.reversedOrder&&(T=N[N.length-b-1]),v=T.getBBox(),this.equalWidths?y=C*(u+d+this.markerLabelGap):w=(y=w)+v.width+o+d,y+v.width>c&&0<b&&0!==C&&(m++,w=(y=C=0)+v.width+o+d,M=M+S+l,S=0),v.height>S&&(S=v.height),T.translate(y,M),C++,!isNaN(h)&&h<=C&&(m++,M=M+S+l,w=o,S=C=0),f.push(T)}h=(v=f.getBBox()).height+2*l-1,"left"==t||"right"==t?(r=(d=v.width+2*o)+e+i,n.style.width=r+"px",this.ieW=r):d=r-e-i-1,i=L.polygon(this.container,[0,d,d,0],[0,0,h,h],this.backgroundColor,this.backgroundAlpha,1,this.borderColor,this.borderAlpha),L.setCN(this.chart,i,"legend-bg"),g.push(i),g.translate(e,s),i.toBack(),e=o,"top"!=t&&"bottom"!=t&&"absolute"!=t&&"outside"!=t||("center"==this.align?e=o+(d-v.width)/2:"right"==this.align&&(e=o+d-v.width)),f.translate(e,l+1),this.titleHeight>h&&(h=this.titleHeight),(s=h+s+a+1)<0&&(s=0),"absolute"!=t&&"outside"!=t&&s>this.chart.divRealHeight&&(n.style.top="0px"),n.style.height=Math.round(s)+"px",p.setSize(this.divWidth,s)},createEntry:function(e){if(!1!==e.visibleInLegend&&!e.hideFromLegend){var i=this,t=i.chart,s=i.useGraphSettings,a=e.markerType;a&&(s=!1),e.legendEntryWidth=i.markerSize,a||(a=i.markerType);var o,n=e.color,r=e.alpha;e.legendKeyColor&&(n=e.legendKeyColor()),e.legendKeyAlpha&&(r=e.legendKeyAlpha()),!0===e.hidden&&(o=n=i.markerDisabledColor);var h,l=e.pattern,d=e.customMarker;d||(d=i.customMarker);var c,u,m=i.container,p=i.markerSize,g=0,f=0,v=p/2;if(s)s=e.type,i.switchType=void 0,"line"==s||"step"==s||"smoothedLine"==s||"ohlc"==s?(h=m.set(),e.hidden||(n=e.lineColorR,o=e.bulletBorderColorR),g=L.line(m,[0,2*p],[p/2,p/2],n,e.lineAlpha,e.lineThickness,e.dashLength),L.setCN(t,g,"graph-stroke"),h.push(g),e.bullet&&(e.hidden||(n=e.bulletColorR),g=L.bullet(m,e.bullet,e.bulletSize,n,e.bulletAlpha,e.bulletBorderThickness,o,e.bulletBorderAlpha))&&(L.setCN(t,g,"graph-bullet"),g.translate(p+1,p/2),h.push(g)),v=0,f=(g=p)/3):(e.getGradRotation&&0===(h=e.getGradRotation())&&(h=180),g=e.fillColorsR,!0===e.hidden&&(g=n),(h=i.createMarker("rectangle",g,e.fillAlphas,e.lineThickness,n,e.lineAlpha,h,l,e.dashLength))&&(v=p,h.translate(v,p/2)),g=p),L.setCN(t,h,"graph-"+s),L.setCN(t,h,"graph-"+e.id);else if(d)h=m.image(d,0,0,p,p);else{var b;isNaN(i.gradientRotation)||(b=180+i.gradientRotation),(h=i.createMarker(a,n,r,void 0,void 0,void 0,b,l))&&h.translate(p/2,p/2)}L.setCN(t,h,"legend-marker"),i.addListeners(h,e),m=m.set([h]),i.switchable&&e.switchable&&m.setAttr("cursor","pointer"),void 0!==e.id&&L.setCN(t,m,"legend-item-"+e.id),L.setCN(t,m,e.className,!0),(o=i.switchType)&&"none"!=o&&0<p&&("x"==o?(c=i.createX()).translate(p/2,p/2):c=i.createV(),!0!==(c.dItem=e).hidden?"x"==o?c.hide():c.show():"x"!=o&&c.hide(),i.switchable||c.hide(),i.addListeners(c,e),e.legendSwitch=c,m.push(c),L.setCN(t,c,"legend-switch")),o=i.color,e.showBalloon&&i.textClickEnabled&&void 0!==i.selectedColor&&(o=i.selectedColor),i.useMarkerColorForLabels&&!l&&(o=n),!0===e.hidden&&(o=i.markerDisabledColor),n=L.massReplace(i.labelText,{"[[title]]":e.title}),void 0!==i.tabIndex&&(m.setAttr("tabindex",i.tabIndex),m.setAttr("role","menuitem"),m.keyup(function(t){13==t.keyCode&&i.clickMarker(e,t)})),t.accessible&&i.accessibleLabel&&(l=L.massReplace(i.accessibleLabel,{"[[title]]":e.title}),t.makeAccessible(m,l)),l=i.fontSize,h&&(p<=l&&(p=p/2+i.ly-l/2+(l+2-p)/2-f,h.translate(v,p),c&&c.translate(c.x,p)),e.legendEntryWidth=h.getBBox().width),n&&(n=L.fixBrakes(n),e.legendTextReal=n,u=i.labelWidth,u=isNaN(u)?L.text(i.container,n,o,t.fontFamily,l,"start"):L.wrappedText(i.container,n,o,t.fontFamily,l,"start",!1,u,0),L.setCN(t,u,"legend-label"),u.translate(i.lx+g,i.ly),m.push(u),i.labelDx=g,t=u.getBBox().width,i.maxLabelWidth<t&&(i.maxLabelWidth=t)),i.entries[i.index]=m,e.legendEntry=i.entries[i.index],e.legendMarker=h,e.legendLabel=u,i.index++}},addListeners:function(t,e){var i=this;t&&t.mouseover(function(t){i.rollOverMarker(e,t)}).mouseout(function(t){i.rollOutMarker(e,t)}).click(function(t){i.clickMarker(e,t)})},rollOverMarker:function(t,e){this.switchable&&this.dispatch("rollOverMarker",t,e),this.dispatch("rollOverItem",t,e)},rollOutMarker:function(t,e){this.switchable&&this.dispatch("rollOutMarker",t,e),this.dispatch("rollOutItem",t,e)},clickMarker:function(t,e){this.switchable&&(!0===t.hidden?this.dispatch("showItem",t,e):this.dispatch("hideItem",t,e)),this.dispatch("clickMarker",t,e)},rollOverLabel:function(t,e){t.hidden||this.textClickEnabled&&t.legendLabel&&t.legendLabel.attr({fill:this.rollOverColor}),this.dispatch("rollOverItem",t,e)},rollOutLabel:function(t,e){if(!t.hidden&&this.textClickEnabled&&t.legendLabel){var i=this.color;void 0!==this.selectedColor&&t.showBalloon&&(i=this.selectedColor),this.useMarkerColorForLabels&&void 0===(i=t.lineColor)&&(i=t.color),t.legendLabel.attr({fill:i})}this.dispatch("rollOutItem",t,e)},clickLabel:function(t,e){this.textClickEnabled?t.hidden||this.dispatch("clickLabel",t,e):this.switchable&&(!0===t.hidden?this.dispatch("showItem",t,e):this.dispatch("hideItem",t,e))},dispatch:function(t,e,i){t={type:t,dataItem:e,target:this,event:i,chart:this.chart},this.chart&&this.chart.handleLegendEvent(t),this.fire(t)},createValue:function(e){var i=this,t=i.fontSize,s=i.chart;if(!1!==e.visibleInLegend&&!e.hideFromLegend){var a=i.maxLabelWidth,o=0;i.forceWidth&&(a=i.labelWidth),i.equalWidths||(i.valueAlign="left"),o={x:0,y:0,width:0,height:0},e.legendLabel&&(o=e.legendLabel.getBBox()),"left"==i.valueAlign&&(a=o.width),o=o.height;var n=a,r=i.markerSize;if(r<t+7&&(r=t+7,L.VML&&(r+=3)),i.valueText&&0<i.valueWidth){var h=i.color;i.useMarkerColorForValues&&(h=e.color,e.legendKeyColor&&(h=e.legendKeyColor())),!0===e.hidden&&(h=i.markerDisabledColor);var l=i.valueText,d=(a=a+i.lx+i.labelDx+i.markerLabelGap+i.valueWidth,"end");"left"==i.valueAlign&&(a-=i.valueWidth,d="start"),t=L.text(i.container,l,h,i.chart.fontFamily,t,d),L.setCN(s,t,"legend-value"),t.translate(a,i.ly),i.entries[i.index].push(t),n+=i.valueWidth+2*i.markerLabelGap,t.dItem=e,i.valueLabels.push(t),r<o+5&&(r=o+5)}i.index++,(s=i.container.rect(e.legendEntryWidth,0,n,r,0,0).attr({stroke:"none",fill:"#fff","fill-opacity":.005})).dItem=e,i.entries[i.index-1].push(s),s.mouseover(function(t){i.rollOverLabel(e,t)}).mouseout(function(t){i.rollOutLabel(e,t)}).click(function(t){i.clickLabel(e,t)})}},createV:function(){var t=this.markerSize;return L.polygon(this.container,[t/5,t/2,t-t/5,t/2],[t/3,t-t/5,t/5,t/1.7],this.switchColor)},createX:function(){var t=(this.markerSize-4)/2,e={stroke:this.switchColor,"stroke-width":3},i=this.container,s=L.line(i,[-t,t],[-t,t]).attr(e);return t=L.line(i,[-t,t],[t,-t]).attr(e),this.container.set([s,t])},createMarker:function(t,e,i,s,a,o,n,r,h){var l=this.markerSize,d=this.container;return a||(a=this.markerBorderColor),a||(a=e),isNaN(s)&&(s=this.markerBorderThickness),isNaN(o)&&(o=this.markerBorderAlpha),L.bullet(d,t,l,e,i,s,a,o,l,n,r,this.chart.path,h)},validateNow:function(){this.invalidateSize()},updateValues:function(){var t,e=this.valueLabels,i=this.chart,s=this.data;if(e)for(t=0;t<e.length;t++){var a=e[t],o=a.dItem;o.periodDataItem=void 0,o.periodPercentDataItem=void 0;var n=" ";if(s)o.value?a.text(o.value):a.text("");else{var r=null;if(void 0!==o.type){r=o.currentDataItem;var h=this.periodValueText;o.legendPeriodValueText&&(h=o.legendPeriodValueText),o.legendPeriodValueTextR&&(h=o.legendPeriodValueTextR),r?(n=this.valueText,o.legendValueText&&(n=o.legendValueText),o.legendValueTextR&&(n=o.legendValueTextR),n=i.formatString(n,r)):h&&i.formatPeriodString&&(h=L.massReplace(h,{"[[title]]":o.title}),n=i.formatPeriodString(h,o))}else n=i.formatString(this.valueText,o);h=o,r&&(h=r);var l,d=this.valueFunction;d&&(n=d(h,n,i.periodDataItem)),this.useMarkerColorForLabels&&!r&&o.lastDataItem&&(r=o.lastDataItem),r?l=i.getBalloonColor(o,r):o.legendKeyColor&&(l=o.legendKeyColor()),o.legendColorFunction&&(l=o.legendColorFunction(h,n,o.periodDataItem,o.periodPercentDataItem)),a.text(n),!o.pattern&&(this.useMarkerColorForValues&&a.setAttr("fill",l),this.useMarkerColorForLabels)&&((a=o.legendMarker)&&(a.setAttr("fill",l),a.setAttr("stroke",l)),(a=o.legendLabel)&&(o.hidden?a.setAttr("fill",this.markerDisabledColor):a.setAttr("fill",l)))}}},renderFix:function(){if(!L.VML&&this.enabled){var t=this.container;t&&t.renderFix()}},destroy:function(){this.div.innerHTML="",L.remove(this.set)}})}(),function(){var f=window.AmCharts;f.AmMap=f.Class({inherits:f.AmChart,construct:function(t){this.cname="AmMap",this.type="map",this.theme=t,this.svgNotSupported="This browser doesn't support SVG. Use Chrome, Firefox, Internet Explorer 9 or later.",this.createEvents("rollOverMapObject","rollOutMapObject","clickMapObject","mouseDownMapObject","selectedObjectChanged","homeButtonClicked","zoomCompleted","dragCompleted","positionChanged","writeDevInfo","click","descriptionClosed"),this.zoomDuration=.6,this.zoomControl=new f.ZoomControl(t),this.fitMapToContainer=!0,this.mouseWheelZoomEnabled=this.backgroundZoomsToTop=!1,this.allowClickOnSelectedObject=this.useHandCursorOnClickableOjects=this.showBalloonOnSelectedObject=!0,this.showObjectsAfterZoom=this.wheelBusy=!1,this.zoomOnDoubleClick=this.useObjectColorForBalloon=!0,this.allowMultipleDescriptionWindows=!1,this.dragMap=this.centerMap=this.linesAboveImages=!0,this.colorSteps=5,this.forceNormalize=!1,this.showAreasInList=!0,this.showLinesInList=this.showImagesInList=!1,this.areasProcessor=new f.AreasProcessor(this),this.areasSettings=new f.AreasSettings(t),this.imagesProcessor=new f.ImagesProcessor(this),this.imagesSettings=new f.ImagesSettings(t),this.linesProcessor=new f.LinesProcessor(this),this.linesSettings=new f.LinesSettings(t),this.initialTouchZoom=1,this.showDescriptionOnHover=!1,f.AmMap.base.construct.call(this,t),this.creditsPosition="bottom-left",this.product="ammap",this.areasClasses={},this.updatableImages=[],f.applyTheme(this,t,this.cname)},initChart:function(){this.zoomInstantly=!0;var t=this.container;if(this.panRequired=!0,this.sizeChanged&&f.hasSVG&&this.chartCreated){this.updatableImages=[],this.freeLabelsSet&&this.freeLabelsSet.remove(),this.freeLabelsSet=t.set(),this.container.setSize(this.realWidth,this.realHeight),this.resizeMap(),this.drawBackground(),this.redrawLabels(),this.drawTitles(),this.processObjects(!0),this.rescaleObjects(),this.zoomControl.init(this,t),this.drawBg();var e=this.smallMap;e&&e.init(this,t),(e=this.valueLegend)&&e.init(this,t),this.sizeChanged=!1,this.zoomToLongLat(this.zLevelTemp,this.zLongTemp,this.zLatTemp,!0),this.previousWidth=this.realWidth,this.previousHeight=this.realHeight,this.updateSmallMap(),this.linkSet.toFront(),this.zoomControl.update&&this.zoomControl.update()}else f.AmMap.base.initChart.call(this),f.hasSVG?(this.dataChanged&&(this.parseData(),this.dispatchDataUpdated=!0,this.dataChanged=!1,t=this.legend)&&(t.position="absolute",t.invalidateSize()),this.createDescriptionsDiv(),this.svgAreas=[],this.svgAreasById={},this.drawChart()):(this.chartDiv.style.textAlign="",this.chartDiv.setAttribute("class","ammapAlert"),this.chartDiv.innerHTML=this.svgNotSupported,this.fire({type:"failed",chart:this}))},storeTemp:function(){if(f.hasSVG&&0<this.realWidth&&0<this.realHeight){var t=this.mapContainer.getBBox();0<t.width&&0<t.height&&(t=this.zoomLongitude(),isNaN(t)||(this.zLongTemp=t),t=this.zoomLatitude(),isNaN(t)||(this.zLatTemp=t),t=this.zoomLevel(),isNaN(t)||(this.zLevelTemp=t))}},invalidateSize:function(){this.storeTemp(),f.AmMap.base.invalidateSize.call(this)},validateSize:function(){this.storeTemp(),f.AmMap.base.validateSize.call(this)},handleWheelReal:function(t){if(!this.wheelBusy){this.stopAnimation();var e=this.zoomLevel(),i=this.zoomControl,s=i.zoomFactor;this.wheelBusy=!0,t=f.fitToBounds(0<t?e*s:e/s,i.minZoomLevel,i.maxZoomLevel),s=this.mouseX/this.mapWidth,i=this.mouseY/this.mapHeight,s=(this.zoomX()-s)*(t/e)+s,e=(this.zoomY()-i)*(t/e)+i,this.zoomTo(t,s,e)}},addLegend:function(t,e){return t.position="absolute",t.autoMargins=!1,t.valueWidth=0,t.switchable=!1,f.AmMap.base.addLegend.call(this,t,e),void 0===t.enabled&&(t.enabled=!0),t},handleLegendEvent:function(){},createDescriptionsDiv:function(){if(!this.descriptionsDiv){var t=document.createElement("div"),e=t.style;e.position="absolute",e.left="0px",e.top="0px",this.descriptionsDiv=t}this.containerDiv.appendChild(this.descriptionsDiv)},drawChart:function(){f.AmMap.base.drawChart.call(this);var t=this.dataProvider;this.dataProvider=t=f.extend(t,new f.MapData,!0),this.areasSettings=f.processObject(this.areasSettings,f.AreasSettings,this.theme),this.imagesSettings=f.processObject(this.imagesSettings,f.ImagesSettings,this.theme),this.linesSettings=f.processObject(this.linesSettings,f.LinesSettings,this.theme);var e,i=this.container;this.mapContainer&&this.mapContainer.remove(),this.mapContainer=i.set(),this.graphsSet.push(this.mapContainer),t.map&&(e=f.maps[t.map]),t.mapVar&&(e=t.mapVar),e?(this.svgData=e.svg,this.getBounds(),this.buildEverything()):(t=t.mapURL)&&this.loadXml(t),this.balloonsSet.toFront()},drawBg:function(){var t=this;t.background.click(function(){t.handleBackgroundClick()}),t.background.mouseover(function(){t.rollOutMapObject(t.previouslyHovered)})},buildEverything:function(){if(0<this.realWidth&&0<this.realHeight){var t=this.container,e=this.dataProvider;isNaN(e.zoomLevel)||(this.mapContainer.scale=e.zoomLevel),this.projection||(this.projection=e.projection,this.projection||(this.projection="equirectangular")),this.updatableImages=[];var i=this.projection;i&&(this.projectionFunction=f[i]),this.projectionFunction||(this.projectionFunction=f.equirectangular),this.dpProjectionFunction=f[e.projection],this.dpProjectionFunction||(this.dpProjectionFunction=f.equirectangular),this.zoomControl=f.processObject(this.zoomControl,f.ZoomControl,this.theme),this.zoomControl.init(this,t),this.drawBg(),this.buildSVGMap(),this.projectionFunction&&i!=e.projection||this.forceNormalize?(this.normalizeMap(),this.changeProjection()):this.fixMapPosition(),(i=this.smallMap)&&((i=f.processObject(i,f.SmallMap,this.theme)).init(this,t),this.smallMap=i),isNaN(e.zoomX)&&isNaN(e.zoomY)&&isNaN(e.zoomLatitude)&&isNaN(e.zoomLongitude)&&(this.centerMap?(i=this.xyToCoordinates(this.mapWidth/2,this.mapHeight/2),e.zoomLongitudeC=i.longitude,e.zoomLatitudeC=i.latitude):(e.zoomX=0,e.zoomY=0),this.zoomInstantly=!0),this.selectObject(this.dataProvider),this.processAreas(),(e=this.valueLegend)&&(this.valueLegend=e=f.processObject(e,f.ValueLegend,this.theme),e.init(this,t)),this.objectList&&(t=this.objectList=f.processObject(this.objectList,f.ObjectList))&&(this.clearObjectList(),t.init(this)),this.dispDUpd(),this.updateSmallMap(),this.linkSet.toFront()}else this.cleanChart()},hideGroup:function(t){this.showHideGroup(t,!1)},showGroup:function(t){this.showHideGroup(t,!0)},showHideGroup:function(t,e){this.showHideReal(this.imagesProcessor.allObjects,t,e),this.showHideReal(this.areasProcessor.allObjects,t,e),this.showHideReal(this.linesProcessor.allObjects,t,e)},showHideReal:function(t,e,i){var s;for(s=0;s<t.length;s++){var a=t[s];if(a.groupId==e){var o=a.displayObject;o&&(i?(a.hidden=!1,o.show()):(a.hidden=!0,o.hide()))}}},makeObjectAccessible:function(t){if(t.accessibleLabel){var e=this.formatString(t.accessibleLabel,t);t.displayObject&&this.makeAccessible(t.displayObject,e,"menuitem")}},update:function(){if(f.hasSVG){f.AmMap.base.update.call(this),this.zoomControl&&this.zoomControl.update&&this.zoomControl.update();for(var t=0,e=this.updatableImages.length;t<e;t++)this.updatableImages[t].update()}},animateMap:function(){var t=this;t.totalFrames=t.zoomDuration*f.updateRate,t.totalFrames+=1,t.frame=0,t.tweenPercent=0,t.balloon.hide(0),setTimeout(function(){t.updateSize.call(t)},1e3/f.updateRate)},updateSize:function(){var t=this,e=t.totalFrames;t.preventHover=!0,t.frame<=e?(t.frame++,1<=(e=f.easeOutSine(0,t.frame,0,1,e))?(e=1,t.preventHover=!1,t.wheelBusy=!1):window.requestAnimationFrame?window.requestAnimationFrame(function(){t.updateSize.call(t)}):setTimeout(function(){t.updateSize.call(t)},1e3/f.updateRate),.8<e&&(t.preventHover=!1)):(e=1,t.preventHover=!1,t.wheelBusy=!1),t.tweenPercent=e,t.rescaleMapAndObjects()},rescaleMapAndObjects:function(){var t=this.initialScale,e=this.initialX,i=this.initialY,s=this.tweenPercent;if(t+=(this.finalScale-t)*s,this.mapContainer.translate(e+(this.finalX-e)*s,i+(this.finalY-i)*s,t,!0),this.areasSettings.adjustOutlineThickness){e=this.svgAreas;for(var a=0;a<e.length;a++)(i=e[a])&&i.setAttr("stroke-width",this.areasSettings.outlineThickness/t/this.mapScale);if(e=this.dataProvider.areas)for(a=0;a<e.length;a++){var o=(i=e[a]).displayObject;o&&o.setAttr("stroke-width",i.outlineThicknessReal/t/this.mapScale)}}this.rescaleObjects(),this.positionChanged(),this.updateSmallMap(),1==s&&this.fire({type:"zoomCompleted",chart:this}),processingObjects||(processingObjects=!0,this.processObjects())},updateSmallMap:function(){this.smallMap&&this.smallMap.update()},rescaleObjects:function(){var t,e=this.mapContainer.scale,i=this.imagesProcessor.objectsToResize;for(t=0;t<i.length;t++){var s=i[t].image,a=i[t].scale,o=i[t].mapImage;isNaN(o.selectedScaleReal)||o!=this.selectedObject||(o.tempScale=a,a*=o.selectedScaleReal),s.translate(s.x,s.y,a/e,!0)}for(i=this.imagesProcessor.labelsToReposition,t=0;t<i.length;t++)(s=i[t]).imageLabel&&this.imagesProcessor.positionLabel(s.imageLabel,s,s.labelPositionReal);if(s=(i=this.linesProcessor).linesToResize)for(t=0;t<s.length;t++)(a=s[t]).line.setAttr("stroke-width",a.thickness/e);for(i=i.objectsToResize,t=0;t<i.length;t++)(s=i[t]).translate(s.x,s.y,1/e,!0)},handleTouchEnd:function(t){this.initialDistance=NaN,this.mouseIsDown=this.isDragging=!1,f.AmMap.base.handleTouchEnd.call(this,t)},handleMouseDown:function(t){if(f.resetMouseOver(),this.mouseIsDown=this.mouseIsOver=!0,this.balloon.hide(0),t&&this.mouseIsOver&&t.preventDefault&&this.panEventsEnabled&&t.preventDefault(),this.chartCreated&&!this.preventHover&&(this.initialTouchZoom=this.zoomLevel(),this.dragMap&&(this.stopAnimation(),this.mapContainerClickX=this.mapContainer.x,this.mapContainerClickY=this.mapContainer.y),t||(t=window.event),t.shiftKey&&!0===this.developerMode&&this.getDevInfo(),t&&t.touches)){var e=this.mouseX,i=this.mouseY,s=t.touches.item(1);s&&this.panEventsEnabled&&this.boundingRect&&(t=s.clientX-this.boundingRect.left,s=s.clientY-this.boundingRect.top,this.middleXP=(e+(t-e)/2)/this.realWidth,this.middleYP=(i+(s-i)/2)/this.realHeight,this.initialDistance=Math.sqrt(Math.pow(t-e,2)+Math.pow(s-i,2)))}},stopDrag:function(){this.isDragging=!1},handleReleaseOutside:function(){if(f.isModern){var t=this;if(f.AmMap.base.handleReleaseOutside.call(t),t.mouseIsDown=!1,setTimeout(function(){t.resetPinch.call(t)},100),!t.preventHover){t.stopDrag(),(e=t.zoomControl)&&e.draggerUp&&e.draggerUp(),t.mapWasDragged=!1;var e=t.mapContainer,i=t.mapContainerClickX,s=t.mapContainerClickY;isNaN(i)||isNaN(s)||!(3<Math.abs(e.x-i)||3<Math.abs(e.y-s))||(t.mapWasDragged=!0,e={type:"dragCompleted",zoomX:t.zoomX(),zoomY:t.zoomY(),zoomLevel:t.zoomLevel(),chart:t},t.fire(e)),(t.mouseIsOver&&!t.mapWasDragged&&!t.skipClick||t.wasTouched&&Math.abs(t.mouseX-t.tmx)<3&&Math.abs(t.mouseY-t.tmy)<3)&&t.fire({type:"click",x:t.mouseX,y:t.mouseY,chart:t}),t.mapContainerClickX=NaN,t.mapContainerClickY=NaN,t.objectWasClicked=!1,t.zoomOnDoubleClick&&t.mouseIsOver&&((e=(new Date).getTime())-t.previousClickTime<200&&40<e-t.previousClickTime&&t.doDoubleClickZoom(),t.previousClickTime=e)}t.wasTouched=!1}},resetPinch:function(){this.mapWasPinched=!1},handleMouseMove:function(t){var e=this;if(f.AmMap.base.handleMouseMove.call(e,t),!t||!t.touches||!e.tapToActivate||e.tapped){e.panEventsEnabled&&e.mouseIsOver&&t&&t.preventDefault&&t.preventDefault();var i=e.previuosMouseX,s=e.previuosMouseY,a=e.mouseX,o=e.mouseY,n=e.zoomControl;if(isNaN(i)&&(i=a),isNaN(s)&&(s=o),e.mouse2X=NaN,e.mouse2Y=NaN,t&&t.touches&&(t=t.touches.item(1))&&e.panEventsEnabled&&e.boundingRect&&(e.mouse2X=t.clientX-e.boundingRect.left,e.mouse2Y=t.clientY-e.boundingRect.top),t=e.mapContainer){var r=e.mouse2X,h=e.mouse2Y;e.pinchTO&&clearTimeout(e.pinchTO),e.pinchTO=setTimeout(function(){e.resetPinch.call(e)},1e3);var l=e.realHeight,d=e.realWidth,c=e.mapWidth,u=e.mapHeight;if(e.mouseIsDown&&e.dragMap&&(3<Math.abs(e.previuosMouseX-e.mouseX)||3<Math.abs(e.previuosMouseY-e.mouseY))&&(e.isDragging=!0),!isNaN(r)){e.stopDrag();var m=Math.sqrt(Math.pow(r-a,2)+Math.pow(h-o,2)),p=e.initialDistance;if(isNaN(p)&&(p=Math.sqrt(Math.pow(r-a,2)+Math.pow(h-o,2))),!isNaN(p)){r=e.initialTouchZoom*m/p,r=f.fitToBounds(r,n.minZoomLevel,n.maxZoomLevel),n=e.zoomLevel(),p=e.middleXP,h=e.middleYP,m=l/u;var g=d/c;p=(e.zoomX()-p*g)*(r/n)+p*g,h=(e.zoomY()-h*m)*(r/n)+h*m,.1<Math.abs(r-n)&&(e.zoomTo(r,p,h,!0),e.mapWasPinched=!0,clearTimeout(e.pinchTO))}}r=t.scale,e.isDragging&&(e.balloon.hide(0),e.positionChanged(),i=t.x+(a-i),s=t.y+(o-s),e.preventDragOut&&(u=-u*r+l/2-e.diffY*e.mapScale*r,l=l/2-e.diffY*e.mapScale*r,i=f.fitToBounds(i,-c*r+d/2,d/2),s=f.fitToBounds(s,u,l)),isNaN(i)||isNaN(s)||(t.translate(i,s,r,!0),e.updateSmallMap())),e.previuosMouseX=a,e.previuosMouseY=o}}},selectObject:function(t,e){var i=this;t||(t=i.dataProvider),t.isOver=!1;var s=t.linkToObject;f.isString(s)&&(s=i.getObjectById(s)),t.useTargetsZoomValues&&s&&(t.zoomX=s.zoomX,t.zoomY=s.zoomY,t.zoomLatitude=s.zoomLatitude,t.zoomLongitude=s.zoomLongitude,t.zoomLevel=s.zoomLevel);var a=i.selectedObject;a&&i.returnInitialColor(a);var o,n,r=!1;if("MapArea"==(i.selectedObject=t).objectType&&(t.autoZoomReal&&(r=!0),o=i.areasSettings.selectedOutlineColor,n=i.areasSettings.selectedOutlineThickness),s&&!r&&(f.isString(s)&&(s=i.getObjectById(s)),isNaN(t.zoomLevel)&&isNaN(t.zoomX)&&isNaN(t.zoomY))){if(i.extendMapData(s))return;i.selectObject(s)}else{if(i.allowMultipleDescriptionWindows||i.closeAllDescriptions(),clearTimeout(i.selectedObjectTimeOut),clearTimeout(i.processObjectsTimeOut),s=i.zoomDuration,!r&&isNaN(t.zoomLevel)&&isNaN(t.zoomX)&&isNaN(t.zoomY)?(i.showDescriptionAndGetUrl(),e||i.processObjects()):(i.selectedObjectTimeOut=setTimeout(function(){i.showDescriptionAndGetUrl.call(i)},1e3*s+200),i.showObjectsAfterZoom?e||(i.processObjectsTimeOut=setTimeout(function(){i.processObjects.call(i)},1e3*s+200)):e||i.processObjects()),s=t.displayObject,r=t.selectedColorReal,"MapImage"==t.objectType){o=i.imagesSettings.selectedOutlineColor,n=i.imagesSettings.selectedOutlineThickness,s=t.image;var h=t.selectedScaleReal;if(!isNaN(h)&&1!=h){var l=t.scale;isNaN(t.tempScale)||(l=t.tempScale),isNaN(l)&&(l=1),t.tempScale=l;var d=t.displayObject;d.translate(d.x,d.y,l*h,!0)}}if(s?(f.removeCN(i,s,"selected-object"),f.setCN(i,s,"selected-object"),t.bringForwardOnHover&&t.displayObject.toFront(),i.outlinesToFront(),t.preserveOriginalAttributes||(s.setAttr("stroke",t.outlineColorReal),void 0!==r&&s.setAttr("fill",r),void 0!==o&&s.setAttr("stroke",o),void 0!==n&&s.setAttr("stroke-width",n),"MapLine"==t.objectType&&((h=t.lineSvg)&&h.setAttr("stroke",r),h=t.arrowSvg)&&(h.setAttr("fill",r),h.setAttr("stroke",r)),(h=t.imageLabel)&&void 0!==(l=t.selectedLabelColorReal)&&h.setAttr("fill",l),t.selectable||(s.setAttr("cursor","default"),h&&h.setAttr("cursor","default")))):i.returnInitialColorReal(t),s=t.groupId)for((h=t.groupArray)||(h=i.getGroupById(s),t.groupArray=h),l=0;l<h.length;l++)if((d=h[l]).isOver=!1,s=d.displayObject,"MapImage"==d.objectType&&(s=d.image),s){var c=d.selectedColorReal;void 0!==c&&s.setAttr("fill",c),void 0!==o&&s.setAttr("stroke",o),void 0!==n&&s.setAttr("stroke-width",n),"MapLine"==d.objectType&&((s=d.lineSvg)&&s.setAttr("stroke",r),s=d.arrowSvg)&&(s.setAttr("fill",r),s.setAttr("stroke",r))}i.rescaleObjects(),i.zoomToSelectedObject(),a!=t&&i.fire({type:"selectedObjectChanged",chart:i})}},returnInitialColor:function(t,e){if(this.returnInitialColorReal(t),e&&(t.isFirst=!1),this.selectedObject.bringForwardOnHover&&(s=this.selectedObject.displayObject)&&s.toFront(),s=t.groupId){var i,s=this.getGroupById(s);for(i=0;i<s.length;i++)this.returnInitialColorReal(s[i]),e&&(s[i].isFirst=!1)}this.outlinesToFront()},outlinesToFront:function(){if(this.outlines)for(var t=0;t<this.outlines.length;t++)this.outlines[t].toFront()},closeAllDescriptions:function(){this.descriptionsDiv.innerHTML=""},fireClosed:function(){this.fire({type:"descriptionClosed",chart:this})},returnInitialColorReal:function(t){t.isOver=!1;var e=t.displayObject;if(e){if(f.removeCN(this,e,"selected-object"),e.toPrevious(),"MapImage"==t.objectType){var i=t.tempScale;isNaN(i)||e.translate(e.x,e.y,i,!0),t.tempScale=NaN,e=t.image}i=t.colorReal,"MapLine"==t.objectType&&((o=t.lineSvg)&&o.setAttr("stroke",i),(o=t.arrowSvg)&&(void 0===(n=t.arrowColor)&&(n=i),o.setAttr("fill",n),o.setAttr("stroke",n)));var s,a,o=t.alphaReal,n=t.outlineAlphaReal,r=t.outlineThicknessReal,h=t.outlineColorReal;if(t.showAsSelected)i=t.selectedColorReal,"MapImage"==t.objectType&&(s=this.imagesSettings.selectedOutlineColor,a=this.imagesSettings.selectedOutlineThickness),"MapArea"==t.objectType&&(s=this.areasSettings.selectedOutlineColor,a=this.areasSettings.selectedOutlineThickness),void 0!==s&&(h=s),void 0!==a&&(r=a);"bubble"==t.type&&(i=void 0),void 0!==i&&e.setAttr("fill",i),(s=t.image)&&(s.setAttr("fill",i),s.setAttr("stroke",h),s.setAttr("stroke-width",r),s.setAttr("fill-opacity",o),s.setAttr("stroke-opacity",n)),"MapArea"==t.objectType&&(i=1,this.areasSettings.adjustOutlineThickness&&(i=this.zoomLevel()*this.mapScale),e.setAttr("stroke",h),e.setAttr("stroke-width",r/i),e.setAttr("fill-opacity",o),e.setAttr("stroke-opacity",n)),(i=t.pattern)&&e.pattern(i,this.mapScale,this.path),(e=t.imageLabel)&&!t.labelInactive&&(t.showAsSelected&&void 0!==t.selectedLabelColor?e.setAttr("fill",t.selectedLabelColor):e.setAttr("fill",t.labelColorReal))}},zoomToRectangle:function(t,e,i,s){var a=this.realWidth,o=this.realHeight,n=this.mapSet.scale,r=this.zoomControl;a=f.fitToBounds(s/o<i/a?.8*a/(i*n):.8*o/(s*n),r.minZoomLevel,r.maxZoomLevel),this.zoomToMapXY(a,(t+i/2)*n,(e+s/2)*n)},zoomToLatLongRectangle:function(t,e,i,s){var a=this.dataProvider,o=this.zoomControl,n=Math.abs(i-t),r=Math.abs(e-s),h=Math.abs(a.rightLongitude-a.leftLongitude);a=Math.abs(a.topLatitude-a.bottomLatitude),o=f.fitToBounds(r/a<n/h?.8*h/n:.8*a/r,o.minZoomLevel,o.maxZoomLevel),this.zoomToLongLat(o,t+(i-t)/2,s+(e-s)/2)},getGroupById:function(t){var e=[];return this.getGroup(this.imagesProcessor.allObjects,t,e),this.getGroup(this.linesProcessor.allObjects,t,e),this.getGroup(this.areasProcessor.allObjects,t,e),e},zoomToGroup:function(t){var e,i,s,a,o;for(t="object"==typeof t?t:this.getGroupById(t),o=0;o<t.length;o++)if(n=t[o].displayObject){var n=(l=n.getBBox()).y,r=l.y+l.height,h=l.x,l=l.x+l.width;(n<e||isNaN(e))&&(e=n),(a<r||isNaN(a))&&(a=r),(h<i||isNaN(i))&&(i=h),(s<l||isNaN(s))&&(s=l)}i+=this.diffX,s+=this.diffX,a+=this.diffY,e+=this.diffY,this.zoomToRectangle(i,e,s-i,a-e)},getGroup:function(t,e,i){var s;if(t)for(s=0;s<t.length;s++){var a=t[s];a.groupId==e&&i.push(a)}},zoomToStageXY:function(t,e,i,s){if(!this.objectWasClicked){var a=this.zoomControl;t=f.fitToBounds(t,a.minZoomLevel,a.maxZoomLevel),a=this.zoomLevel();var o=this.mapSet.getBBox();e=this.xyToCoordinates((e-this.mapContainer.x)/a-o.x*this.mapScale,(i-this.mapContainer.y)/a-o.y*this.mapScale),this.zoomToLongLat(t,e.longitude,e.latitude,s)}},zoomToLongLat:function(t,e,i,s){e=this.coordinatesToXY(e,i),this.zoomToMapXY(t,e.x,e.y,s)},zoomToMapXY:function(t,e,i,s){var a=this.mapWidth,o=this.mapHeight;this.zoomTo(t,-e/a*t+this.realWidth/a/2,-i/o*t+this.realHeight/o/2,s)},zoomToObject:function(t){if(t){var e=t.zoomLatitude,i=t.zoomLongitude;isNaN(t.zoomLatitudeC)||(e=t.zoomLatitudeC),isNaN(t.zoomLongitudeC)||(i=t.zoomLongitudeC);var s=t.zoomLevel,a=this.zoomInstantly,o=t.zoomX,n=t.zoomY,r=this.realWidth,h=this.realHeight;isNaN(s)||(isNaN(e)||isNaN(i)?this.zoomTo(s,o,n,a):this.zoomToLongLat(s,i,e,a)),this.zoomInstantly=!1,"MapImage"==t.objectType&&isNaN(t.zoomX)&&isNaN(t.zoomY)&&isNaN(t.zoomLatitude)&&isNaN(t.zoomLongitude)&&!isNaN(t.latitude)&&!isNaN(t.longitude)&&this.zoomToLongLat(t.zoomLevel,t.longitude,t.latitude),"MapArea"==t.objectType&&(a=t.displayObject.getBBox(),o=this.mapScale,e=(a.x+this.diffX)*o,i=(a.y+this.diffY)*o,s=a.width*o,a=a.height*o,r=t.autoZoomReal&&isNaN(t.zoomLevel)?a/h<s/r?.8*r/s:.8*h/a:t.zoomLevel,h=this.zoomControl,r=f.fitToBounds(r,h.minZoomLevel,h.maxZoomLevel),isNaN(t.zoomX)&&isNaN(t.zoomY)&&isNaN(t.zoomLatitude)&&isNaN(t.zoomLongitude)&&this.zoomToMapXY(r,e+s/2,i+a/2)),this.zoomControl.update()}},zoomToSelectedObject:function(){this.zoomToObject(this.selectedObject)},zoomTo:function(t,e,i,s){var a=this.zoomControl;t=f.fitToBounds(t,a.minZoomLevel,a.maxZoomLevel),a=this.zoomLevel(),isNaN(e)&&(e=this.realWidth/this.mapWidth,e=(this.zoomX()-.5*e)*(t/a)+.5*e),isNaN(i)&&(i=this.realHeight/this.mapHeight,i=(this.zoomY()-.5*i)*(t/a)+.5*i),this.stopAnimation(),isNaN(t)||(a=this.mapContainer,this.initialX=a.x,this.initialY=a.y,this.initialScale=a.scale,this.finalX=this.mapWidth*e,this.finalY=this.mapHeight*i,this.finalScale=t,this.finalX!=this.initialX||this.finalY!=this.initialY||this.finalScale!=this.initialScale?s?(this.tweenPercent=1,this.rescaleMapAndObjects(),this.wheelBusy=!1):this.animateMap():this.wheelBusy=!1)},loadXml:function(t){var e;window.XMLHttpRequest&&(e=new XMLHttpRequest),e.overrideMimeType&&e.overrideMimeType("text/xml"),e.open("GET",t,!1),e.send(),this.parseXMLObject(e.responseXML),this.svgData&&this.buildEverything()},stopAnimation:function(){this.frame=this.totalFrames},processObjects:function(t){var e=this.selectedObject;if(processingObjects)return this.imagesProcessor.process(e),void setTimeout(function(){processingObjects=!1},300);if(0<e.images.length||0<e.areas.length||0<e.lines.length||e==this.dataProvider||t){t=this.container;var i=this.stageImagesContainer;i&&i.remove(),this.stageImagesContainer=i=t.set(),this.trendLinesSet.push(i);var s=this.stageLinesContainer;s&&s.remove(),this.stageLinesContainer=s=t.set(),this.trendLinesSet.push(s);var a=this.mapImagesContainer;a&&a.remove(),this.mapImagesContainer=a=t.set(),this.mapContainer.push(a);var o=this.mapLinesContainer;o&&o.remove(),this.mapLinesContainer=o=t.set(),this.mapContainer.push(o),this.linesAboveImages?(a.toFront(),i.toFront(),o.toFront(),s.toFront()):(o.toFront(),s.toFront(),a.toFront(),i.toFront()),e&&(this.imagesProcessor.reset(),this.linesProcessor.reset(),this.linesAboveImages?(this.imagesProcessor.process(e),this.linesProcessor.process(e)):(this.linesProcessor.process(e),this.imagesProcessor.process(e))),this.rescaleObjects()}},processAreas:function(){this.areasProcessor.process(this.dataProvider)},buildSVGMap:function(){f.remove(this.mapSet);var t,e=this.svgData.g.path,i=this.container,s=i.set();for(this.svgAreas=[],this.svgAreasById={},void 0===e.length&&(e=[e]),t=0;t<e.length;t++){var a=e[t],o=a.d,n=a.title;a.titleTr&&(n=a.titleTr);var r=i.path(o);if(r.id=a.id,this.areasSettings.preserveOriginalAttributes)for(var h in r.customAttr={},a)"d"!=h&&"id"!=h&&"title"!=h&&(r.customAttr[h]=a[h]);a.outline&&(r.outline=!0),r.path=o,this.svgAreasById[a.id]={area:r,title:n,className:a.class},this.svgAreas.push(r),s.push(r)}this.mapSet=s,this.mapContainer.push(s),this.resizeMap()},centerAlign:function(){},setProjection:function(t){this.projection=t,this.chartCreated=!1,this.buildEverything()},addObjectEventListeners:function(t,s){var a=this;t.mousedown(function(t){a.mouseDownMapObject(s,t)}).mouseup(function(t){a.clickMapObject(s,t)}).mouseover(function(t){a.balloonX=NaN,a.rollOverMapObject(s,!0,t)}).mouseout(function(t){a.balloonX=NaN,a.rollOutMapObject(s,t)}).touchend(function(t){Math.abs(a.mouseX-a.tmx)<4&&Math.abs(a.mouseY-a.tmy)<4&&(a.tapped=!0),a.tapToActivate&&!a.tapped||a.mapWasDragged||a.mapWasPinched||(a.balloonX=NaN,a.rollOverMapObject(s,!0,t),a.clickMapObject(s,t))}).touchstart(function(t){a.tmx=a.mouseX,a.tmy=a.mouseY,a.mouseDownMapObject(s,t)}).keyup(function(t){13==t.keyCode&&a.clickMapObject(s,t)}).focus(function(t){var e,i;"MapImage"!=s.objectType||isNaN(s.longitude)||(e=s.longitude,i=s.latitude),"MapArea"==s.objectType&&(e=a.getAreaCenterLongitude(s),i=a.getAreaCenterLatitude(s)),e=a.coordinatesToStageXY(e,i),a.balloonX=e.x,a.balloonY=e.y,a.rollOverMapObject(s,!0,t)}).blur(function(t){a.rollOutMapObject(s,t)})},checkIfSelected:function(t){if((i=this.selectedObject)==t)return!0;if(i=i.groupId){var e,i=this.getGroupById(i);for(e=0;e<i.length;e++)if(i[e]==t)return!0}return!1},clearMap:function(){this.chartDiv.innerHTML="",this.clearObjectList()},clearObjectList:function(){var t=this.objectList;t&&t.div&&(t.div.innerHTML="")},checkIfLast:function(t){if(t){var e=t.parentNode;if(e&&e.lastChild==t)return!0}return!1},showAsRolledOver:function(t){var e=t.displayObject;if(!t.showAsSelected&&e&&!t.isOver){e.node.onmouseout=function(){},e.node.onmouseover=function(){},e.node.onclick=function(){},!t.isFirst&&t.bringForwardOnHover&&(e.toFront(),t.isFirst=!0);var i,s=t.rollOverColorReal;if(t.preserveOriginalAttributes&&(s=void 0),"bubble"==t.type&&(s=void 0),null==s&&(isNaN(t.rollOverBrightnessReal)||(s=f.adjustLuminosity(t.colorReal,t.rollOverBrightnessReal/100))),null!=s&&("MapImage"==t.objectType?(i=t.image)&&i.setAttr("fill",s):"MapLine"==t.objectType?((i=t.lineSvg)&&i.setAttr("stroke",s),(i=t.arrowSvg)&&(i.setAttr("fill",s),i.setAttr("stroke",s))):e.setAttr("fill",s)),(s=t.imageLabel)&&!t.labelInactive&&null!=(i=t.labelRollOverColorReal)&&s.setAttr("fill",i),null!=(s=t.rollOverOutlineColorReal)&&("MapImage"==t.objectType?(i=t.image)&&i.setAttr("stroke",s):e.setAttr("stroke",s)),"MapImage"==t.objectType?(s=this.imagesSettings.rollOverOutlineThickness,(i=t.image)&&(isNaN(s)||i.setAttr("stroke-width",s))):(s=this.areasSettings.rollOverOutlineThickness,isNaN(s)||e.setAttr("stroke-width",s)),"MapArea"==t.objectType){s=this.areasSettings,i=t.rollOverAlphaReal,isNaN(i)||e.setAttr("fill-opacity",i),i=s.rollOverOutlineAlpha,isNaN(i)||e.setAttr("stroke-opacity",i),i=1,this.areasSettings.adjustOutlineThickness&&(i=this.zoomLevel()*this.mapScale);var a=s.rollOverOutlineThickness;isNaN(a)||e.setAttr("stroke-width",a/i),(s=s.rollOverPattern)&&e.pattern(s,this.mapScale,this.path)}"MapImage"==t.objectType&&(s=t.rollOverScaleReal,isNaN(s)||1==s||(i=e.scale,isNaN(i)&&(i=1),t.tempScale=i,e.translate(e.x,e.y,i*s,!0))),this.useHandCursorOnClickableOjects&&this.checkIfClickable(t)&&e.setAttr("cursor","pointer"),t.mouseEnabled&&this.addObjectEventListeners(e,t),t.isOver=!0}this.outlinesToFront()},rollOverMapObject:function(t,e,i){if(this.chartCreated&&(this.handleMouseMove(),(a=this.previouslyHovered)&&a!=t?(!1===this.checkIfSelected(a)&&(this.returnInitialColor(a,!0),this.previouslyHovered=null),this.balloon.hide(0)):clearTimeout(this.hoverInt),!this.preventHover)){if(!1===this.checkIfSelected(t)){if(a=t.groupId){var s,a=this.getGroupById(a);for(s=0;s<a.length;s++)a[s]!=t&&this.showAsRolledOver(a[s])}this.showAsRolledOver(t)}else(a=t.displayObject)&&(this.allowClickOnSelectedObject?a.setAttr("cursor","pointer"):a.setAttr("cursor","default"));this.showDescriptionOnHover?this.showDescription(t):!this.showBalloonOnSelectedObject&&this.checkIfSelected(t)||!1===e||(s=this.balloon,this.balloon.fixedPosition=!1,a="",void 0!==(e=t.colorReal)&&this.useObjectColorForBalloon||(e=s.fillColor),(s=t.balloonTextReal)&&(a=this.formatString(s,t)),this.balloonLabelFunction&&(a=this.balloonLabelFunction(t,this)),a&&""!==a&&this.showBalloon(a,e,!1,this.balloonX,this.balloonY)),i={type:"rollOverMapObject",mapObject:t,chart:this,event:i},t.isOver=!0,this.fire(i),this.previouslyHovered=t}},longitudeToX:function(t){return(this.longitudeToCoordinate(t)+this.diffX*this.mapScale)*this.zoomLevel()+this.mapContainer.x},latitudeToY:function(t){return(this.latitudeToCoordinate(t)+this.diffY*this.mapScale)*this.zoomLevel()+this.mapContainer.y},latitudeToStageY:function(t){return this.latitudeToCoordinate(t)*this.zoomLevel()+this.mapContainer.y+this.diffY*this.mapScale},longitudeToStageX:function(t){return this.longitudeToCoordinate(t)*this.zoomLevel()+this.mapContainer.x+this.diffX*this.mapScale},stageXToLongitude:function(t){return t=(t-this.mapContainer.x)/this.zoomLevel(),this.coordinateToLongitude(t)},stageYToLatitude:function(t){return t=(t-this.mapContainer.y)/this.zoomLevel(),this.coordinateToLatitude(t)},rollOutMapObject:function(t,e){if(this.hideBalloon(),t&&this.chartCreated&&t.isOver){this.checkIfSelected(t)||this.returnInitialColor(t);var i={type:"rollOutMapObject",mapObject:t,chart:this,event:e};t.isOver=!1,this.fire(i)}},formatString:function(t,e){var i=this.nf,s=this.pf,a=e.title;e.titleTr&&(a=e.titleTr),null==a&&(a="");var o=e.value;o=isNaN(o)?"":f.formatNumber(o,i),i=e.percents,i=isNaN(i)?"":f.formatNumber(i,s),null==(s=e.description)&&(s="");var n=e.customData;return null==n&&(n=""),f.massReplace(t,{"[[title]]":a,"[[value]]":o,"[[percent]]":i,"[[description]]":s,"[[customData]]":n})},mouseDownMapObject:function(t,e){this.fire({type:"mouseDownMapObject",mapObject:t,chart:this,event:e})},clickMapObject:function(t,e){var i=this;if(e&&(e.touches||isNaN(t.zoomLevel)&&isNaN(t.zoomX)&&isNaN(t.zoomY)||i.hideBalloon()),i.chartCreated&&!i.preventHover&&i.checkTouchDuration(e)&&!i.mapWasDragged&&i.checkIfClickable(t)&&!i.mapWasPinched){i.selectObject(t);var s=i.zoomLevel(),a=i.mapSet.getBBox();s=i.xyToCoordinates((i.mouseX-i.mapContainer.x)/s-a.x*i.mapScale,(i.mouseY-i.mapContainer.y)/s-a.y*i.mapScale),i.clickLatitude=s.latitude,i.clickLongitude=s.longitude,e&&e.touches&&setTimeout(function(){i.showBalloonAfterZoom.call(i)},1e3*i.zoomDuration),i.fire({type:"clickMapObject",mapObject:t,chart:i,event:e}),i.objectWasClicked=!0}},showBalloonAfterZoom:function(){var t=this.clickLongitude,e=this.clickLatitude,i=this.selectedObject;"MapImage"!=i.objectType||isNaN(i.longitude)||(t=i.longitude,e=i.latitude),t=this.coordinatesToStageXY(t,e),this.balloonX=t.x,this.balloonY=t.y,this.rollOverMapObject(this.selectedObject,!0)},checkIfClickable:function(t){var e=this.allowClickOnSelectedObject;return!((this.selectedObject!=t||!e)&&(this.selectedObject==t&&!e||!(!0===t.selectable||"MapArea"==t.objectType&&t.autoZoomReal||t.url||t.linkToObject||0<t.images.length||0<t.lines.length)&&isNaN(t.zoomLevel)&&isNaN(t.zoomX)&&isNaN(t.zoomY)&&!t.description))},resizeMap:function(){var t=this.mapSet;if(t){var e=1,i=t.getBBox(),s=this.realWidth,a=this.realHeight,o=i.width;i=i.height,0<o&&0<i&&(this.fitMapToContainer&&(e=i/a<o/s?s/o:a/i),t.translate(0,0,e,!0),this.mapScale=e,this.mapHeight=i*e,this.mapWidth=o*e)}},zoomIn:function(){var t=this.zoomLevel()*this.zoomControl.zoomFactor;this.zoomTo(t)},zoomOut:function(){var t=this.zoomLevel()/this.zoomControl.zoomFactor;this.zoomTo(t)},moveLeft:function(){var t=this.zoomX()+this.zoomControl.panStepSize;this.zoomTo(this.zoomLevel(),t,this.zoomY())},moveRight:function(){var t=this.zoomX()-this.zoomControl.panStepSize;this.zoomTo(this.zoomLevel(),t,this.zoomY())},moveUp:function(){var t=this.zoomY()+this.zoomControl.panStepSize;this.zoomTo(this.zoomLevel(),this.zoomX(),t)},moveDown:function(){var t=this.zoomY()-this.zoomControl.panStepSize;this.zoomTo(this.zoomLevel(),this.zoomX(),t)},zoomX:function(){return this.mapSet?Math.round(1e4*this.mapContainer.x/this.mapWidth)/1e4:NaN},zoomY:function(){return this.mapSet?Math.round(1e4*this.mapContainer.y/this.mapHeight)/1e4:NaN},goHome:function(){this.selectObject(this.dataProvider),this.fire({type:"homeButtonClicked",chart:this})},zoomLevel:function(){return Math.round(1e5*this.mapContainer.scale)/1e5},showDescriptionAndGetUrl:function(){var t=this.selectedObject;if(t){this.showDescription();var e=t.url;if(e)f.getURL(e,t.urlTarget);else if(e=t.linkToObject){if(f.isString(e)){var i=this.getObjectById(e);if(i)return void this.selectObject(i)}e&&t.passZoomValuesToTarget&&(e.zoomLatitude=this.zoomLatitude(),e.zoomLongitude=this.zoomLongitude(),e.zoomLevel=this.zoomLevel()),this.extendMapData(e)||this.selectObject(e)}}},extendMapData:function(t){var e=t.objectType;if("MapImage"!=e&&"MapArea"!=e&&"MapLine"!=e)return f.extend(t,new f.MapData,!0),this.dataProvider=t,this.zoomInstantly=!0,this.validateData(),!0},showDescription:function(t){if(t||(t=this.selectedObject),this.allowMultipleDescriptionWindows||this.closeAllDescriptions(),t.description){var e=t.descriptionWindow;e&&e.close(),e=new f.DescriptionWindow,t.descriptionWindow=e;var i=t.descriptionWindowWidth,s=t.descriptionWindowHeight,a=t.descriptionWindowLeft,o=t.descriptionWindowTop,n=t.descriptionWindowRight,r=t.descriptionWindowBottom;isNaN(n)||(a=this.realWidth-n),isNaN(r)||(o=this.realHeight-r);var h=t.descriptionWindowX;isNaN(h)||(a=h),h=t.descriptionWindowY,isNaN(h)||(o=h),isNaN(a)&&(a=(a=this.mouseX)>this.realWidth/2?a-i-20:a+20),isNaN(o)&&(o=this.mouseY),e.maxHeight=s,h=t.title,t.titleTr&&(h=t.titleTr),e.show(this,this.descriptionsDiv,t.description,h),(t=e.div.style).position="absolute",t.width=i+"px",t.maxHeight=s+"px",isNaN(r)||(o-=e.div.offsetHeight),isNaN(n)||(a-=e.div.offsetWidth),t.left=a+"px",t.top=o+"px"}},parseXMLObject:function(t){var e={root:{}};this.parseXMLNode(e,"root",t),this.svgData=e.root.svg,this.getBounds()},getBounds:function(){var t=this.dataProvider;try{var e=this.svgData.defs["amcharts:ammap"];t.leftLongitude=Number(e.leftLongitude),t.rightLongitude=Number(e.rightLongitude),t.topLatitude=Number(e.topLatitude),t.bottomLatitude=Number(e.bottomLatitude),t.projection=e.projection;var i=e.wrappedLongitudes;i&&(t.rightLongitude+=360),t.wrappedLongitudes=i}catch(t){}},recalcLongitude:function(t){return this.dataProvider.wrappedLongitudes&&t<this.dataProvider.leftLongitude?Number(t)+360:t},latitudeToCoordinate:function(t){var e,i=this.dataProvider;if(this.mapSet){e=i.topLatitude;var s=i.bottomLatitude;"mercator"==i.projection&&(t=this.mercatorLatitudeToCoordinate(t),e=this.mercatorLatitudeToCoordinate(e),s=this.mercatorLatitudeToCoordinate(s)),e=(t-e)/(s-e)*this.mapHeight}return e},longitudeToCoordinate:function(t){t=this.recalcLongitude(t);var e,i=this.dataProvider;return this.mapSet&&(e=(t-(e=i.leftLongitude))/(i.rightLongitude-e)*this.mapWidth),e},mercatorLatitudeToCoordinate:function(t){return 89.5<t&&(t=89.5),t<-89.5&&(t=-89.5),t=f.degreesToRadians(t),f.radiansToDegrees(.5*Math.log((1+Math.sin(t))/(1-Math.sin(t)))/2)},zoomLatitude:function(){if(this.mapContainer){var t=this.mapSet.getBBox(),e=(-this.mapContainer.x+this.previousWidth/2)/this.zoomLevel()-t.x*this.mapScale;return t=(-this.mapContainer.y+this.previousHeight/2)/this.zoomLevel()-t.y*this.mapScale,this.xyToCoordinates(e,t).latitude}},zoomLongitude:function(){if(this.mapContainer){var t=this.mapSet.getBBox(),e=(-this.mapContainer.x+this.previousWidth/2)/this.zoomLevel()-t.x*this.mapScale;return t=(-this.mapContainer.y+this.previousHeight/2)/this.zoomLevel()-t.y*this.mapScale,this.xyToCoordinates(e,t).longitude}},getAreaCenterLatitude:function(t){t=t.displayObject.getBBox();var e=this.mapScale,i=this.mapSet.getBBox();return this.xyToCoordinates((t.x+t.width/2+this.diffX)*e-i.x*e,(t.y+t.height/2+this.diffY)*e-i.y*e).latitude},getAreaCenterLongitude:function(t){t=t.displayObject.getBBox();var e=this.mapScale,i=this.mapSet.getBBox();return this.xyToCoordinates((t.x+t.width/2+this.diffX)*e-i.x*e,(t.y+t.height/2+this.diffY)*e-i.y*e).longitude},milesToPixels:function(t){var e=this.dataProvider;return this.mapWidth/(e.rightLongitude-e.leftLongitude)*t/69.172},kilometersToPixels:function(t){var e=this.dataProvider;return this.mapWidth/(e.rightLongitude-e.leftLongitude)*t/111.325},handleBackgroundClick:function(){if(this.backgroundZoomsToTop&&!this.mapWasDragged){var t=this.dataProvider;if(this.checkIfClickable(t))this.clickMapObject(t);else{var e=t.zoomX,i=t.zoomY,s=t.zoomLongitude,a=t.zoomLatitude;t=t.zoomLevel,isNaN(e)||isNaN(i)||this.zoomTo(t,e,i),isNaN(s)||isNaN(a)||this.zoomToLongLat(t,s,a,!0)}}},parseXMLNode:function(t,e,i,s){var a,o,n;if(void 0===s&&(s=""),i){var r=i.childNodes.length;for(a=0;a<r;a++){var h=(o=i.childNodes[a]).nodeName,l=o.nodeValue?this.trim(o.nodeValue):"",d=!1;if(o.attributes&&0<o.attributes.length&&(d=!0),0!==o.childNodes.length||""!==l||!1!==d)if(3==o.nodeType||4==o.nodeType){if(""!==l){for(n in o=0,t[e])t[e].hasOwnProperty(n)&&o++;o?t[e]["#text"]=l:t[e]=l}}else if(1==o.nodeType){var c;if(void 0!==t[e][h]?void 0===t[e][h].length?(c=t[e][h],t[e][h]=[],t[e][h].push(c),t[e][h].push({}),c=t[e][h][1]):"object"==typeof t[e][h]&&(t[e][h].push({}),c=t[e][h][t[e][h].length-1]):(t[e][h]={},c=t[e][h]),o.attributes&&o.attributes.length)for(l=0;l<o.attributes.length;l++)c[o.attributes[l].name]=o.attributes[l].value;void 0!==t[e][h].length?this.parseXMLNode(t[e][h],t[e][h].length-1,o,s+"  "):this.parseXMLNode(t[e],h,o,s+"  ")}}for(n in o=0,i="",t[e])"#text"==n?i=t[e][n]:o++;0===o&&void 0===t[e].length&&(t[e]=i)}},doDoubleClickZoom:function(){if(!this.mapWasDragged){var t=this.zoomLevel()*this.zoomControl.zoomFactor;this.zoomToStageXY(t,this.mouseX,this.mouseY)}},getDevInfo:function(){var t=this.zoomLevel(),e=this.mapSet.getBBox();return e=this.xyToCoordinates((this.mouseX-this.mapContainer.x)/t-e.x*this.mapScale,(this.mouseY-this.mapContainer.y)/t-e.y*this.mapScale),e=(e=(e=(e=(e=(e=(e="zoomLevel:"+(t={chart:this,type:"writeDevInfo",zoomLevel:t,zoomX:this.zoomX(),zoomY:this.zoomY(),zoomLatitude:this.zoomLatitude(),zoomLongitude:this.zoomLongitude(),latitude:e.latitude,longitude:e.longitude,left:this.mouseX,top:this.mouseY,right:this.realWidth-this.mouseX,bottom:this.realHeight-this.mouseY,percentLeft:Math.round(this.mouseX/this.realWidth*100)+"%",percentTop:Math.round(this.mouseY/this.realHeight*100)+"%",percentRight:Math.round((this.realWidth-this.mouseX)/this.realWidth*100)+"%",percentBottom:Math.round((this.realHeight-this.mouseY)/this.realHeight*100)+"%"}).zoomLevel+", zoomLongitude:"+t.zoomLongitude+", zoomLatitude:"+t.zoomLatitude+"\n")+"zoomX:"+t.zoomX+", zoomY:"+t.zoomY+"\n")+"latitude:"+t.latitude+", longitude:"+t.longitude+"\n")+"left:"+t.left+", top:"+t.top+"\n")+"right:"+t.right+", bottom:"+t.bottom+"\n")+"left:"+t.percentLeft+", top:"+t.percentTop+"\n")+"right:"+t.percentRight+", bottom:"+t.percentBottom+"\n",t.str=e,this.fire(t),t},getXY:function(t,e,i){return void 0!==t&&(-1!=String(t).indexOf("%")?(t=Number(t.split("%").join("")),i&&(t=100-t),t=Number(t)*e/100):i&&(t=e-t)),t},getObjectById:function(t){var e=this.dataProvider;if(e.areas){var i=this.getObject(t,e.areas);if(i)return i}return(i=this.getObject(t,e.images))?i:(t=this.getObject(t,e.lines))?t:void 0},getObject:function(t,e){var i;if(e)for(i=0;i<e.length;i++){var s=e[i];if(s.id==t)return s;if(s.areas){var a=this.getObject(t,s.areas);if(a)return a}if(a=this.getObject(t,s.images))return a;if(s=this.getObject(t,s.lines))return s}},parseData:function(){var t=this.dataProvider;this.processObject(t.areas,t,"area"),this.processObject(t.images,t,"image"),this.processObject(t.lines,t,"line")},processObject:function(t,e,i){var s;if(t)for(s=0;s<t.length;s++){var a=t[s];a.parentObject=e,"area"==i&&f.extend(a,new f.MapArea(this.theme),!0),"image"==i&&(a=f.extend(a,new f.MapImage(this.theme),!0)),"line"==i&&(a=f.extend(a,new f.MapLine(this.theme),!0)),(t[s]=a).areas&&this.processObject(a.areas,a,"area"),a.images&&this.processObject(a.images,a,"image"),a.lines&&this.processObject(a.lines,a,"line")}},positionChanged:function(){var t={type:"positionChanged",zoomX:this.zoomX(),zoomY:this.zoomY(),zoomLevel:this.zoomLevel(),chart:this};this.fire(t)},getX:function(t,e){return this.getXY(t,this.realWidth,e)},getY:function(t,e){return this.getXY(t,this.realHeight,e)},trim:function(t){if(t){var e;for(e=0;e<t.length;e++)if(-1===" \n\r\t\f\v            ​\u2028\u2029　".indexOf(t.charAt(e))){t=t.substring(e);break}for(e=t.length-1;0<=e;e--)if(-1===" \n\r\t\f\v            ​\u2028\u2029　".indexOf(t.charAt(e))){t=t.substring(0,e+1);break}return-1===" \n\r\t\f\v            ​\u2028\u2029　".indexOf(t.charAt(0))?t:""}},destroy:function(){f.AmMap.base.destroy.call(this)},x2c:function(t){var e=this.dataProvider.leftLongitude;return Math.round(this.unscaledMapWidth*(t-e)/(this.dataProvider.rightLongitude-e)*100)/100},y2c:function(t){var e=this.dataProvider.topLatitude;return Math.round(this.unscaledMapHeight*(t-e)/(this.dataProvider.bottomLatitude-e)*100)/100},normalize:function(t){if(!t.pathsArray){var e;if(t.normalized)e=t.normalized;else{var i=f.normalizePath(t.node);e=t.node.getAttribute("d"),t.normalized=e,i.maxX>this.maxMapX&&(this.maxMapX=i.maxX),i.minX<this.minMapX&&(this.minMapX=i.minX),i.maxY>this.maxMapY&&(this.maxMapY=i.maxY),i.minY<this.minMapY&&(this.minMapY=i.minY)}t.node.setAttribute("d",e)}},redraw:function(t){var e=(e=(e=t.normalized).split(" Z").join("")).split("M");t.pathsArray=[];for(var i=0;i<e.length;i++)if(s=e[i]){for(var s=s.split("L"),a=[],o=0;o<s.length;o++)if(s[o]){var n=s[o].split(" ");n=this.xyToCoordinates(Number(n[1])-this.minMapX,Number(n[2])-this.minMapY,this.dpProjectionFunction,this.sourceMapWidth,this.sourceMapHeight),a.push([n.longitude,n.latitude])}t.pathsArray.push(a)}for(e="",i=0;i<t.pathsArray.length;i++)e+=this.redrawArea(t.pathsArray[i]);t.node.setAttribute("d",e),t.path=e},redrawArea:function(t){for(var e=!1,i="",s=0;s<t.length;s++){var a=t[s][0],o=t[s][1],n=f.degreesToRadians(t[s][0]),r=f.degreesToRadians(t[s][1]);r=this.projectionFunction(n,r),n=f.roundTo(this.x2c(f.radiansToDegrees(r[0])),3),r=f.roundTo(this.y2c(f.radiansToDegrees(r[1])),3),n<this.minMapXX&&(this.minMapXX=n,this.leftLongLat={longitude:a,latitude:o}),n>this.maxMapXX&&(this.maxMapXX=n,this.rightLongLat={longitude:a,latitude:o}),r<this.minMapYY&&(this.minMapYY=r,this.topLongLat={longitude:a,latitude:o}),r>this.maxMapYY&&(this.maxMapYY=r,this.bottomLongLat={longitude:a,latitude:o}),e?i+=" L ":(i+=" M ",e=!0),i+=n+" "+r}return i+" Z "},normalizeMap:function(){var t=(h=f.degreesToRadians(this.dataProvider.leftLongitude))+((l=f.degreesToRadians(this.dataProvider.rightLongitude))-h)/2,e=(n=f.degreesToRadians(this.dataProvider.topLatitude))+((r=f.degreesToRadians(this.dataProvider.bottomLatitude))-n)/2,i=this.dpProjectionFunction(t,n)[1],s=this.dpProjectionFunction(t,r)[1],a=this.dpProjectionFunction(h,e)[0],o=this.dpProjectionFunction(l,e)[0],n=f.equirectangular(t,n),r=f.equirectangular(t,r),h=(i=(n[1]-r[1])/(i-s),f.equirectangular(h,e)),l=f.equirectangular(l,e);for(a=(h[0]-l[0])/(a-o),this.minMapX=1/0,this.maxMapX=-1/0,this.minMapY=1/0,this.maxMapY=-1/0,o=0;o<this.svgAreas.length;o++)this.normalize(this.svgAreas[o]);this.sourceMapHeight=Math.abs(this.maxMapY-this.minMapY),this.sourceMapWidth=Math.abs(this.maxMapX-this.minMapX),this.unscaledMapWidth=this.sourceMapWidth*a,this.unscaledMapHeight=this.sourceMapHeight*i,this.diffY=this.diffX=0},fixMapPosition:function(){var t=f.degreesToRadians(this.dataProvider.leftLongitude),e=f.degreesToRadians(this.dataProvider.rightLongitude),i=f.degreesToRadians(this.dataProvider.topLatitude),s=f.degreesToRadians(this.dataProvider.bottomLatitude),a=t+(e-t)/2,o=i+(s-i)/2,n=this.dpProjectionFunction(a,i)[1],r=this.dpProjectionFunction(a,s)[1],h=this.dpProjectionFunction(t,o)[0],l=this.dpProjectionFunction(e,o)[0];for(this.sourceMapHeight=this.mapHeight/this.mapScale,this.sourceMapWidth=this.mapWidth/this.mapScale,this.unscaledMapWidth=(t-e)/(h-l)*this.sourceMapWidth,this.unscaledMapHeight=(i-s)/(n-r)*this.sourceMapHeight,e=this.coordinatesToXY(f.radiansToDegrees(a),f.radiansToDegrees(i)),t=this.coordinatesToXY(f.radiansToDegrees(t),f.radiansToDegrees(o)),i=o=1/0,s=0;s<this.svgAreas.length;s++)(a=this.svgAreas[s].getBBox()).y<o&&(o=a.y),a.x<i&&(i=a.x);for(this.diffY=e.y/this.mapScale-o,this.diffX=t.x/this.mapScale-i,s=0;s<this.svgAreas.length;s++)this.svgAreas[s].translate(this.diffX,this.diffY)},changeProjection:function(){this.minMapXX=1/0,this.maxMapXX=-1/0,this.minMapYY=1/0,this.maxMapYY=-1/0,this.projectionChanged=!1;for(var t=0;t<this.svgAreas.length;t++)this.redraw(this.svgAreas[t]);this.projectionChanged=!0,this.resizeMap()},coordinatesToXY:function(t,e){var i,s;return i=!1,this.dataProvider&&(i=this.dataProvider.wrappedLongitudes)&&(t=this.recalcLongitude(t)),this.projectionFunction?(s=this.projectionFunction(f.degreesToRadians(t),f.degreesToRadians(e)),i=this.mapScale*f.roundTo(this.x2c(f.radiansToDegrees(s[0])),3),s=this.mapScale*f.roundTo(this.y2c(f.radiansToDegrees(s[1])),3)):(i=this.longitudeToCoordinate(t),s=this.latitudeToCoordinate(e)),{x:i,y:s}},coordinatesToStageXY:function(t,e){var i;return{x:(i=this.coordinatesToXY(t,e)).x*this.zoomLevel()+this.mapContainer.x,y:i=i.y*this.zoomLevel()+this.mapContainer.y}},stageXYToCoordinates:function(t,e){var i=this.mapSet.getBBox(),s=(t-this.mapContainer.x)/this.zoomLevel()-i.x*this.mapScale;return i=(e-this.mapContainer.y)/this.zoomLevel()-i.y*this.mapScale,this.xyToCoordinates(s,i)},xyToCoordinates:function(t,e,i,s,a){var o;if(isNaN(s)&&(s=this.mapWidth),isNaN(a)&&(a=this.mapHeight),i||(i=this.projectionFunction),o=i.invert){var n=(d=this.dataProvider.leftLongitude)+((c=this.dataProvider.rightLongitude)-d)/2,r=(h=this.dataProvider.topLatitude)+((l=this.dataProvider.bottomLatitude)-h)/2,h=f.radiansToDegrees(i(f.degreesToRadians(n),f.degreesToRadians(h))[1]),l=f.radiansToDegrees(i(f.degreesToRadians(n),f.degreesToRadians(l))[1]),d=f.radiansToDegrees(i(f.degreesToRadians(d),f.degreesToRadians(r))[0]),c=f.radiansToDegrees(i(f.degreesToRadians(c),f.degreesToRadians(r))[0]);this.projectionChanged&&(h=f.radiansToDegrees(i(f.degreesToRadians(this.topLongLat.longitude),f.degreesToRadians(this.topLongLat.latitude))[1]),l=f.radiansToDegrees(i(f.degreesToRadians(this.bottomLongLat.longitude),f.degreesToRadians(this.bottomLongLat.latitude))[1]),d=f.radiansToDegrees(i(f.degreesToRadians(this.leftLongLat.longitude),f.degreesToRadians(this.leftLongLat.latitude))[0]),c=f.radiansToDegrees(i(f.degreesToRadians(this.rightLongLat.longitude),f.degreesToRadians(this.rightLongLat.latitude))[0])),e=o(t=f.degreesToRadians(t/s*(c-d)+d),e=f.degreesToRadians(e/a*(l-h)+h)),o=f.radiansToDegrees(e[0]),e=f.radiansToDegrees(e[1])}else o=this.coordinateToLongitude(t),e=this.coordinateToLatitude(e);return{longitude:f.roundTo(o,4),latitude:f.roundTo(e,4)}},coordinateToLatitude:function(t,e){var i;if(void 0===e&&(e=this.mapHeight),this.mapSet){var s=this.dataProvider,a=s.bottomLatitude;i=s.topLatitude,"mercator"==s.projection?(s=this.mercatorLatitudeToCoordinate(a),i=this.mercatorLatitudeToCoordinate(i),i=2*f.degreesToRadians(t*(s-i)/e+i),i=f.radiansToDegrees(2*Math.atan(Math.exp(i))-.5*Math.PI)):i=t/e*(a-i)+i}return Math.round(1e6*i)/1e6},coordinateToLongitude:function(t,e){var i,s=this.dataProvider;return void 0===e&&(e=this.mapWidth),this.mapSet&&(i=t/e*(s.rightLongitude-s.leftLongitude)+s.leftLongitude),Math.round(1e6*i)/1e6}})}(),function(){var O=window.AmCharts;O.ZoomControl=O.Class({construct:function(t){this.cname="ZoomControl",this.panStepSize=.1,this.zoomFactor=2,this.maxZoomLevel=64,this.minZoomLevel=1,this.panControlEnabled=!1,this.zoomControlEnabled=!0,this.buttonRollOverColor="#DADADA",this.buttonFillColor="#FFFFFF",this.buttonFillAlpha=1,this.buttonBorderColor="#000000",this.buttonBorderAlpha=.1,this.buttonIconAlpha=this.buttonBorderThickness=1,this.gridColor=this.buttonIconColor="#000000",this.homeIconFile="homeIcon.gif",this.gridBackgroundColor="#000000",this.draggerAlpha=this.gridAlpha=this.gridBackgroundAlpha=0,this.draggerSize=this.buttonSize=31,this.iconSize=11,this.homeButtonEnabled=!0,this.buttonCornerRadius=2,this.gridHeight=5,this.roundButtons=!0,this.top=this.left=10,O.applyTheme(this,t,this.cname)},init:function(t,e){var i=this;i.chart=t,O.remove(i.set);var s=e.set();O.setCN(t,s,"zoom-control");var a,o=i.buttonSize,n=i.zoomControlEnabled,r=i.panControlEnabled,h=i.buttonFillColor,l=i.buttonFillAlpha,d=i.buttonBorderThickness,c=i.buttonBorderColor,u=i.buttonBorderAlpha,m=i.buttonCornerRadius,p=i.buttonRollOverColor,g=i.gridHeight,f=i.zoomFactor,v=i.minZoomLevel,b=i.maxZoomLevel,N=i.buttonIconAlpha,C=i.buttonIconColor,w=i.roundButtons,M=t.svgIcons,S=t.getX(i.left),y=t.getY(i.top);if(isNaN(i.right)||(S=t.getX(i.right,!0),S=r?S-3*o:S-o),isNaN(i.bottom)||(y=t.getY(i.bottom,!0),n&&(y-=g+3*o),y=r?y-3*o:i.homeButtonEnabled?y-.5*o:y+o),s.translate(S,y),i.previousDY=NaN,S=o/4-1,n){a=e.set(),O.setCN(t,a,"zoom-control-zoom"),s.push(a),i.set=s,i.zoomSet=a,5<g&&(n=O.rect(e,o+6,g+2*o+6,i.gridBackgroundColor,i.gridBackgroundAlpha,0,"#000000",0,4),O.setCN(t,n,"zoom-bg"),n.translate(-3,-3),n.mouseup(function(){i.handleBgUp()}).touchend(function(){i.handleBgUp()}),a.push(n));var T=o;w&&(T=o/1.5),i.draggerSize=T;var L=Math.log(b/v)/Math.log(f)+1;1e3<L&&(L=1e3),n=g/L;var x,A=e.set();for(A.translate((o-T)/2+1,1,NaN,!0),a.push(A),x=1;x<L;x++)y=o+x*n,y=O.line(e,[1,T-2],[y,y],i.gridColor,i.gridAlpha,1),O.setCN(t,y,"zoom-grid"),A.push(y);(y=new O.SimpleButton).setDownHandler(i.draggerDown,i),y.setClickHandler(i.draggerUp,i),y.init(e,T,n,h,l,d,c,u,m,p),O.setCN(t,y.set,"zoom-dragger"),a.push(y.set),y.set.setAttr("opacity",i.draggerAlpha),i.dragger=y.set,i.previousY=NaN,y=new O.SimpleButton,M?(T=e.set(),L=O.line(e,[-S,S],[0,0],C,N,1),x=O.line(e,[0,0],[-S,S],C,N,1),T.push(L),T.push(x),y.svgIcon=T):y.setIcon(t.pathToImages+"plus.gif",i.iconSize),y.setClickHandler(t.zoomIn,t),y.init(e,o,o,h,l,d,c,u,m,p,N,C,w),O.setCN(t,y.set,"zoom-in"),a.push(y.set),y=new O.SimpleButton,M?y.svgIcon=O.line(e,[-S,S],[0,0],C,N,1):y.setIcon(t.pathToImages+"minus.gif",i.iconSize),y.setClickHandler(t.zoomOut,t),y.init(e,o,o,h,l,d,c,u,m,p,N,C,w),y.set.translate(0,g+o),O.setCN(t,y.set,"zoom-out"),a.push(y.set),g-=n,b=Math.log(b/100)/Math.log(f),i.realStepSize=g/(b-Math.log(v/100)/Math.log(f)),i.realGridHeight=g,i.stepMax=b}r&&(r=e.set(),O.setCN(t,r,"zoom-control-pan"),s.push(r),a&&a.translate(o,4*o),f=new O.SimpleButton,M?f.svgIcon=O.line(e,[S/5,S/5-S,S/5],[-S,0,S],C,N,1):f.setIcon(t.pathToImages+"panLeft.gif",i.iconSize),f.setClickHandler(t.moveLeft,t),f.init(e,o,o,h,l,d,c,u,m,p,N,C,w),f.set.translate(0,o),O.setCN(t,f.set,"pan-left"),r.push(f.set),f=new O.SimpleButton,M?f.svgIcon=O.line(e,[-S/5,S-S/5,-S/5],[-S,0,S],C,N,1):f.setIcon(t.pathToImages+"panRight.gif",i.iconSize),f.setClickHandler(t.moveRight,t),f.init(e,o,o,h,l,d,c,u,m,p,N,C,w),f.set.translate(2*o,o),O.setCN(t,f.set,"pan-right"),r.push(f.set),f=new O.SimpleButton,M?f.svgIcon=O.line(e,[-S,0,S],[S/5,S/5-S,S/5],C,N,1):f.setIcon(t.pathToImages+"panUp.gif",i.iconSize),f.setClickHandler(t.moveUp,t),f.init(e,o,o,h,l,d,c,u,m,p,N,C,w),f.set.translate(o,0),O.setCN(t,f.set,"pan-up"),r.push(f.set),f=new O.SimpleButton,M?f.svgIcon=O.line(e,[-S,0,S],[-S/5,S-S/5,-S/5],C,N,1):f.setIcon(t.pathToImages+"panDown.gif",i.iconSize),f.setClickHandler(t.moveDown,t),f.init(e,o,o,h,l,d,c,u,m,p,N,C,w),f.set.translate(o,2*o),O.setCN(t,f.set,"pan-down"),r.push(f.set),s.push(r)),i.homeButtonEnabled&&(r=new O.SimpleButton,M?r.svgIcon=O.polygon(e,[-S,0,S,S-1,S-1,2,2,-2,-2,1-S,1-S],[0,-S,0,0,S-1,S-1,2,2,S-1,S-1,0],C,N,1,C,N):r.setIcon(t.pathToImages+i.homeIconFile,i.iconSize),r.setClickHandler(t.goHome,t),i.panControlEnabled&&(u=l=0),r.init(e,o,o,h,l,d,c,u,m,p,N,C,w),i.panControlEnabled?r.set.translate(o,o):a&&a.translate(0,1.5*o),O.setCN(t,r.set,"pan-home"),s.push(r.set)),i.update()},draggerDown:function(){this.chart.stopDrag(),this.isDragging=!0},draggerUp:function(){this.isDragging=!1},handleBgUp:function(){var t=this.chart;t.zoomTo(100*Math.pow(this.zoomFactor,this.stepMax-(t.mouseY-this.zoomSet.y-this.set.y-this.buttonSize-this.realStepSize/2)/this.realStepSize))},update:function(){var t;t=this.zoomFactor;var e,i=this.realStepSize,s=this.stepMax,a=this.dragger,o=this.buttonSize,n=this.chart;n&&(this.isDragging?(n.stopDrag(),e=a.y+(n.mouseY-this.previousY),e=O.fitToBounds(e,o,this.realGridHeight+o),n.zoomTo(100*Math.pow(t,s-(e-o)/i),NaN,NaN,!0)):e=(s-(t=Math.log(n.zoomLevel()/100)/Math.log(t)))*i+o,this.previousY=n.mouseY,this.previousDY!=e&&a&&(a.translate((this.buttonSize-this.draggerSize)/2,e),this.previousDY=e))}})}(),function(){var g=window.AmCharts;g.SimpleButton=g.Class({construct:function(){},init:function(t,e,i,s,a,o,n,r,h,l,d,c,u){var m,p=this;p.rollOverColor=l,p.color=s,l=(p.container=t).set(),p.set=l,u?(e/=2,(s=g.circle(t,e,s,a,o,n,r)).translate(e,e)):s=g.rect(t,e,i,s,a,o,n,r,h),l.push(s),(a=p.iconPath)&&(o=(e-(m=p.iconSize))/2,u&&(o=(2*e-m)/2),m=t.image(a,o,(i-m)/2,m,m)),p.svgIcon&&(m=p.svgIcon,u?m.translate(e,e):m.translate(e/2,e/2)),l.setAttr("cursor","pointer"),m&&(l.push(m),m.setAttr("opacity",d),m.node.style.pointerEvents="none"),s.mousedown(function(){p.handleDown()}).touchstart(function(){p.handleDown()}).mouseup(function(){p.handleUp()}).touchend(function(){p.handleUp()}).mouseover(function(){p.handleOver()}).mouseout(function(){p.handleOut()}),p.bg=s},setIcon:function(t,e){this.iconPath=t,this.iconSize=e},setClickHandler:function(t,e){this.clickHandler=t,this.scope=e},setDownHandler:function(t,e){this.downHandler=t,this.scope=e},handleUp:function(){var t=this.clickHandler;t&&t.call(this.scope)},handleDown:function(){var t=this.downHandler;t&&t.call(this.scope)},handleOver:function(){this.container.chart.skipClick=!0,this.bg.setAttr("fill",this.rollOverColor)},handleOut:function(){this.container.chart.skipClick=!1,this.bg.setAttr("fill",this.color)}})}(),function(){var g=window.AmCharts;g.SmallMap=g.Class({construct:function(t){this.cname="SmallMap",this.mapColor="#e6e6e6",this.rectangleColor="#FFFFFF",this.top=this.right=10,this.minimizeButtonWidth=23,this.backgroundColor="#9A9A9A",this.backgroundAlpha=1,this.borderColor="#FFFFFF",this.iconColor="#000000",this.borderThickness=3,this.borderAlpha=1,this.size=.2,this.enabled=!0,g.applyTheme(this,t,this.cname)},init:function(t,e){var i=this;if(i.enabled){i.chart=t,i.container=e,i.width=t.realWidth*i.size,i.height=t.realHeight*i.size,g.remove(i.mapSet),g.remove(i.allSet),g.remove(i.set);var s=e.set();i.set=s,g.setCN(t,s,"small-map");var a=e.set();i.allSet=a,s.push(a),i.buildSVGMap();var o=i.borderThickness,n=i.borderColor,r=g.rect(e,i.width+o,i.height+o,i.backgroundColor,i.backgroundAlpha,o,n,i.borderAlpha);g.setCN(t,r,"small-map-bg"),r.translate(-o/2,-o/2),a.push(r),r.toBack(),r=i.minimizeButtonWidth;var h,l,d=new g.SimpleButton,c=r/2;t.svgIcons?d.svgIcon=g.line(e,[-c/2,0,c/2],[-c/4,c/4,-c/4],i.iconColor,1,1):d.setIcon(t.pathToImages+"arrowDown.gif",r),d.setClickHandler(i.minimize,i),d.init(e,r,r,n,1,1,n,1),g.setCN(t,d.set,"small-map-down"),d=d.set,i.downButtonSet=d,s.push(d);var u,m,p=new g.SimpleButton;t.svgIcons?p.svgIcon=g.line(e,[-c/2,0,c/2],[c/4,-c/4,c/4],i.iconColor,1,1):p.setIcon(t.pathToImages+"arrowUp.gif",r),p.setClickHandler(i.maximize,i),p.init(e,r,r,n,1,1,n,1),g.setCN(t,p.set,"small-map-up"),n=p.set,(i.upButtonSet=n).hide(),s.push(n),isNaN(i.top)||(h=t.getY(i.top)+o,m=0),isNaN(i.bottom)||(h=t.getY(i.bottom,!0)-i.height-o,m=i.height-r+o/2),isNaN(i.left)||(l=t.getX(i.left)+o,u=-o/2),isNaN(i.right)||(l=t.getX(i.right,!0)-i.width-o,u=i.width-r+o/2),(o=e.set()).clipRect(1,1,i.width,i.height),a.push(o),i.rectangleC=o,s.translate(l,h),d.translate(u,m),n.translate(u,m),a.mouseup(function(){i.handleMouseUp()}),i.drawRectangle()}else g.remove(i.allSet),g.remove(i.downButtonSet),g.remove(i.upButtonSet)},minimize:function(){this.downButtonSet.hide(),this.upButtonSet.show(),this.allSet.hide()},maximize:function(){this.downButtonSet.show(),this.upButtonSet.hide(),this.allSet.show()},buildSVGMap:function(){var t,e=this.chart,i={fill:this.mapColor,stroke:this.mapColor,"stroke-opacity":1},s=this.container,a=s.set();for(g.setCN(e,a,"small-map-image"),t=0;t<e.svgAreas.length;t++){var o=s.path(e.svgAreas[t].path).attr(i);a.push(o)}this.allSet.push(a),i=a.getBBox(),s=this.size*e.mapScale,t=-i.x*s,o=-i.y*s;var n=0,r=0;e.centerMap&&(n=(this.width-i.width*s)/2,r=(this.height-i.height*s)/2),this.mapWidth=i.width*s,this.mapHeight=i.height*s,t+=n,o+=r,this.dx=n,this.dy=r,a.translate(t,o,s),this.mapSet=a,this.mapX=t,this.mapY=o},update:function(){var t=this.chart;if(t){var e=t.zoomLevel(),i=this.width,s=this.height,a=i/(t.realWidth*e),o=t.mapContainer.getBBox(),n=(i/=e,s/=e,this.rectangle);n.translate(-(t.mapContainer.x+o.x*e)*a+this.dx,-(t.mapContainer.y+o.y*e)*a+this.dy),0<i&&0<s&&(n.setAttr("width",Math.ceil(i+1)),n.setAttr("height",Math.ceil(s+1))),this.rWidth=i,this.rHeight=s}},drawRectangle:function(){var t=this.rectangle;g.remove(t),t=g.rect(this.container,10,10,"#000",0,1,this.rectangleColor,1),g.setCN(this.chart,t,"small-map-rectangle"),this.rectangleC.push(t),this.rectangle=t},handleMouseUp:function(){var t=this.chart,e=t.zoomLevel();t.zoomToMapXY(e,(t.mouseX-this.set.x-this.mapX)/this.size+t.diffX*t.mapScale,(t.mouseY-this.set.y-this.mapY)/this.size+t.diffY*t.mapScale)}})}(),function(){var M=window.AmCharts;M.AreasProcessor=M.Class({construct:function(t){this.chart=t},process:function(t){this.updateAllAreas(),this.allObjects=[],t=t.areas;var e=this.chart;e.outlines=[];var i,s,a=t.length,o=0,n=!1,r=!1;for(i=0;i<a;i++)(s=t[i]).value=Number(s.value),s=s.value,isNaN(s)||((!1===n||n<s)&&(n=s),(!1===r||s<r)&&(r=s),o+=Math.abs(s));for(this.minValue=r,this.maxValue=n,isNaN(e.minValue)||(this.minValue=e.minValue),isNaN(e.maxValue)||(this.maxValue=e.maxValue),e.maxValueReal=n,e.minValueReal=r,i=0;i<a;i++)s=t[i],isNaN(s.value)?s.percents=void 0:(s.percents=(s.value-r)/o*100,r==n&&(s.percents=100));for(i=0;i<a;i++)s=t[i],this.createArea(s);e.outlinesToFront()},updateAllAreas:function(){var t,e=this.chart,i=e.areasSettings,s=i.unlistedAreasColor,a=i.unlistedAreasAlpha,o=i.unlistedAreasOutlineColor,n=i.unlistedAreasOutlineAlpha,r=e.svgAreas,h=e.dataProvider,l=h.areas,d={};for(t=0;t<l.length;t++)d[l[t].id]=l[t];for(t=0;t<r.length;t++){if(l=r[t],i.preserveOriginalAttributes){if(l.customAttr)for(var c in l.customAttr)l.setAttr(c,l.customAttr[c])}else{null!=s&&l.setAttr("fill",s),isNaN(a)||l.setAttr("fill-opacity",a),null!=o&&l.setAttr("stroke",o),isNaN(n)||l.setAttr("stroke-opacity",n);var u=i.outlineThickness;i.adjustOutlineThickness&&(u=u/e.zoomLevel()/e.mapScale),l.setAttr("stroke-width",u)}M.setCN(e,l,"map-area-unlisted"),h.getAreasFromMap&&!d[l.id]&&((u=new M.MapArea(e.theme)).parentObject=h,u.id=l.id,u.outline=l.outline,h.areas.push(u))}},createArea:function(t){var e=this.chart,i=e.svgAreasById[t.id],s=e.areasSettings;if(i&&i.className){var a=e.areasClasses[i.className];a&&(s=M.processObject(a,M.AreasSettings,e.theme))}var o=s.color,n=s.alpha,r=s.outlineThickness,h=s.rollOverColor,l=s.selectedColor,d=s.rollOverAlpha,c=s.rollOverBrightness,u=s.outlineColor,m=s.outlineAlpha,p=s.balloonText,g=s.selectable,f=s.pattern,v=s.rollOverOutlineColor,b=s.bringForwardOnHover,N=s.preserveOriginalAttributes;this.allObjects.push(t),t.chart=e,t.baseSettings=s,t.autoZoomReal=null==t.autoZoom?s.autoZoom:t.autoZoom,null==(a=t.color)&&(a=o);var C,w=t.alpha;isNaN(w)&&(w=n),n=t.rollOverAlpha,isNaN(n)&&(n=d),isNaN(n)&&(n=w),null==(d=t.rollOverColor)&&(d=h),null==(h=t.pattern)&&(h=f),null==(f=t.selectedColor)&&(f=l),void 0===(l=t.balloonText)&&(l=p),null==s.colorSolid||isNaN(t.value)||((p=Math.floor((t.value-this.minValue)/((this.maxValue-this.minValue)/e.colorSteps)))==e.colorSteps&&p--,p*=1/(e.colorSteps-1),this.maxValue==this.minValue&&(p=1),t.colorReal=M.getColorFade(a,s.colorSolid,p)),null!=t.color&&(t.colorReal=t.color),null==t.selectable&&(t.selectable=g),null==t.colorReal&&(t.colorReal=o),null==(o=t.outlineColor)&&(o=u),u=t.outlineAlpha,isNaN(u)&&(u=m),m=t.outlineThickness,isNaN(m)&&(m=r),null==(r=t.rollOverOutlineColor)&&(r=v),null==(v=t.rollOverBrightness)&&(v=c),null==t.bringForwardOnHover&&(t.bringForwardOnHover=b),null==t.preserveOriginalAttributes&&(t.preserveOriginalAttributes=N),isNaN(s.selectedBrightness)||(f=M.adjustLuminosity(t.colorReal,s.selectedBrightness/100)),t.alphaReal=w,t.rollOverColorReal=d,t.rollOverAlphaReal=n,t.balloonTextReal=l,t.selectedColorReal=f,t.outlineColorReal=o,t.outlineAlphaReal=u,t.rollOverOutlineColorReal=r,t.outlineThicknessReal=m,t.patternReal=h,t.rollOverBrightnessReal=v,t.accessibleLabel||(t.accessibleLabel=s.accessibleLabel),M.processDescriptionWindow(s,t),i&&(c=i.area,b=i.title,t.enTitle=i.title,b&&!t.title&&(t.title=b),(i=e.language)?(b=M.mapTranslations)&&(i=b[i])&&i[t.enTitle]&&(t.titleTr=i[t.enTitle]):t.titleTr=void 0,c)&&(void 0===(i=t.tabIndex)&&(i=s.tabIndex),void 0!==i&&c.setAttr("tabindex",i),t.displayObject=c,t.outline&&(w=0,t.alphaReal=0,t.rollOverAlphaReal=0,t.mouseEnabled=!1,e.outlines.push(c),c.node.setAttribute("pointer-events","none")),t.mouseEnabled&&e.addObjectEventListeners(c,t),null!=a&&(C=a),null!=t.colorReal&&(C=t.showAsSelected||e.selectedObject==t?t.selectedColorReal:t.colorReal),c.node.setAttribute("class",""),M.setCN(e,c,"map-area"),M.setCN(e,c,"map-area-"+c.id),s.adjustOutlineThickness&&(m=m/e.zoomLevel()/e.mapScale),t.preserveOriginalAttributes||(c.setAttr("fill",C),c.setAttr("stroke",o),c.setAttr("stroke-opacity",u),c.setAttr("stroke-width",m),c.setAttr("fill-opacity",w)),e.makeObjectAccessible(t),h&&c.pattern(h,e.mapScale,e.path),t.hidden&&c.hide())}})}(),function(){var e=window.AmCharts;e.AreasSettings=e.Class({construct:function(t){this.cname="AreasSettings",this.alpha=1,this.autoZoom=!1,this.balloonText="[[title]]",this.color="#FFCC00",this.colorSolid="#990000",this.unlistedAreasAlpha=1,this.unlistedAreasColor="#DDDDDD",this.outlineColor="#FFFFFF",this.outlineThickness=this.outlineAlpha=1,this.selectedColor=this.rollOverOutlineColor="#CC0000",this.unlistedAreasOutlineColor="#504F64",this.unlistedAreasOutlineAlpha=1,this.descriptionWindowWidth=250,this.bringForwardOnHover=this.adjustOutlineThickness=!0,this.accessibleLabel="[[title]] [[value]] [[description]]",e.applyTheme(this,t,this.cname)}})}(),function(){var O=window.AmCharts;O.ImagesProcessor=O.Class({construct:function(t){this.chart=t,this.reset()},process:function(t){var e,i=t.images;for(e=i.length-1;0<=e;e--){var s=i[e];(!processingObjects||-1<s.title.indexOf("flightID="))&&(this.createImage(s,e),s.parentArray=i)}this.counter=e,t.parentObject&&t.remainVisible&&this.process(t.parentObject)},createImage:function(t,e){(t=O.processObject(t,O.MapImage)).arrays=[],isNaN(e)&&(this.counter++,e=this.counter);var i=this.chart,s=i.container,a=i.mapImagesContainer,o=i.stageImagesContainer,n=i.imagesSettings;t.remove&&t.remove();var r=n.color,h=n.alpha,l=n.rollOverColor,d=n.rollOverOutlineColor,c=n.selectedColor,u=n.balloonText,m=n.outlineColor,p=n.outlineAlpha,g=n.outlineThickness,f=n.selectedScale,v=n.rollOverScale,b=n.selectable,N=n.labelPosition,C=n.labelColor,w=n.labelFontSize,M=n.bringForwardOnHover,S=n.labelRollOverColor,y=n.rollOverBrightness,T=n.selectedLabelColor;t.index=e,t.chart=i,t.baseSettings=i.imagesSettings;var L=s.set();t.displayObject=L;var x,A=t.color;return null==A&&(A=r),r=t.alpha,isNaN(r)&&(r=h),null==t.bringForwardOnHover&&(t.bringForwardOnHover=M),h=t.outlineAlpha,isNaN(h)&&(h=p),null==(p=t.rollOverColor)&&(p=l),null==(l=t.selectedColor)&&(l=c),void 0===(c=t.balloonText)&&(c=u),null==(u=t.outlineColor)&&(u=m),t.outlineColorReal=u,m=t.outlineThickness,isNaN(m)&&(m=g),(g=t.labelPosition)||(g=N),null==(N=t.labelColor)&&(N=C),null==(C=t.labelRollOverColor)&&(C=S),null==(S=t.selectedLabelColor)&&(S=T),T=t.labelFontSize,isNaN(T)&&(T=w),w=t.selectedScale,isNaN(w)&&(w=f),f=t.rollOverScale,isNaN(f)&&(f=v),null==(v=t.rollOverBrightness)&&(v=y),null==t.selectable&&(t.selectable=b),t.colorReal=A,isNaN(n.selectedBrightness)||(l=O.adjustLuminosity(t.colorReal,n.selectedBrightness/100)),t.alphaReal=r,t.rollOverColorReal=p,t.balloonTextReal=c,t.selectedColorReal=l,t.labelColorReal=N,t.labelRollOverColorReal=C,t.selectedLabelColorReal=S,t.labelFontSizeReal=T,t.labelPositionReal=g,t.selectedScaleReal=w,t.rollOverScaleReal=f,t.rollOverOutlineColorReal=d,t.rollOverBrightnessReal=v,t.accessibleLabel||(t.accessibleLabel=n.accessibleLabel),O.processDescriptionWindow(n,t),t.centeredReal=null==t.centered?n.centered:t.centered,d=t.type,v=t.imageURL,f=t.svgPath,w=t.width,T=t.height,b=t.scale,isNaN(t.percentWidth)||(w=t.percentWidth/100*i.realWidth),isNaN(t.percentHeight)||(T=t.percentHeight/100*i.realHeight),v||d||f||(d="circle",w=1,h=r=0),p=y=0,n=t.selectedColorReal,d?(isNaN(w)&&(w=10),isNaN(T)&&(T=10),"kilometers"==t.widthAndHeightUnits&&(w=i.kilometersToPixels(t.width),T=i.kilometersToPixels(t.height)),"miles"==t.widthAndHeightUnits&&(w=i.milesToPixels(t.width),T=i.milesToPixels(t.height)),"circle"!=d&&"bubble"!=d||(T=w),x=this.createPredefinedImage(A,u,m,d,w,T),p=y=0,t.centeredReal?(isNaN(t.right)||(y=w*b),isNaN(t.bottom)||(p=T*b)):(y=w*b/2,p=T*b/2),x.translate(y,p,b,!0)):v?(isNaN(w)&&(w=10),isNaN(T)&&(T=10),(x=s.image(v,0,0,w,T)).node.setAttribute("preserveAspectRatio","none"),x.setAttr("opacity",r),t.centeredReal&&(y=isNaN(t.right)?-w/2:w/2,p=isNaN(t.bottom)?-T/2:T/2,x.translate(y,p,NaN,!0))):f&&(v=(x=s.path(f)).getBBox(),t.centeredReal?(y=-v.x*b-v.width*b/2,isNaN(t.right)||(y=-y),p=-v.y*b-v.height*b/2,isNaN(t.bottom)||(p=-p)):y=p=0,x.translate(y,p,b,!0),x.x=y,x.y=p),x&&(L.push(x),(t.image=x).setAttr("stroke-opacity",h),x.setAttr("stroke-width",m),x.setAttr("stroke",u),x.setAttr("fill-opacity",r),"bubble"!=d&&x.setAttr("fill",A),O.setCN(i,x,"map-image"),null!=t.id&&O.setCN(i,x,"map-image-"+t.id)),A=t.labelColorReal,!t.showAsSelected&&i.selectedObject!=t||null==n||(x&&x.setAttr("fill",n),A=t.selectedLabelColorReal),x=null,void 0!==t.label&&(x=O.text(s,t.label,A,i.fontFamily,t.labelFontSizeReal,t.labelAlign),O.setCN(i,x,"map-image-label"),void 0!==t.id&&O.setCN(i,x,"map-image-label-"+t.id),A=t.labelBackgroundAlpha,(r=t.labelBackgroundColor)&&0<A&&(h=x.getBBox(),s=O.rect(s,h.width+16,h.height+10,r,A),O.setCN(i,s,"map-image-label-background"),null!=t.id&&O.setCN(i,s,"map-image-label-background-"+t.id),L.push(s),t.labelBG=s),t.imageLabel=x,L.push(x),O.setCN(i,L,"map-image-container"),null!=t.id&&O.setCN(i,L,"map-image-container-"+t.id),this.labelsToReposition.push(t),t.arrays.push({arr:this.labelsToReposition,el:t})),s=!(!isNaN(t.latitude)&&!isNaN(t.longitude)),t.lineId&&(x=this.chart.getObjectById(t.lineId))&&0<x.longitudes.length&&(s=!1),s?o.push(L):a.push(L),L.toBack(),L&&(L.rotation=t.rotation,isNaN(t.rotation)||L.rotate(t.rotation),t.arrays.push({arr:this.allSvgObjects,el:L}),this.allSvgObjects.push(L)),this.allObjects.push(t),i.makeObjectAccessible(t),void 0===(a=t.tabIndex)&&(a=i.imagesSettings.tabIndex),void 0!==a&&L.setAttr("tabindex",a),t.arrays.push({arr:this.allObjects,el:t}),isNaN(t.longitude)||isNaN(t.latitude)||!t.fixedSize||(t.objToResize={image:L,mapImage:t,scale:1},this.objectsToResize.push(t.objToResize),t.arrays.push({arr:this.objectsToResize,el:t.objToResize})),this.updateSizeAndPosition(t),t.mouseEnabled&&i.addObjectEventListeners(L,t),t.hidden&&L.hide(),O.removeFromArray(i.updatableImages,t),t.animateAlongLine&&(i.updatableImages.push(t),t.delayAnimateAlong()),t},updateSizeAndPosition:function(t){var e,i=this.chart,s=t.displayObject,a=i.getX(t.left),o=i.getY(t.top),n=t.image.getBBox();isNaN(t.right)||(a=i.getX(t.right,!0)-n.width*t.scale),isNaN(t.bottom)||(o=i.getY(t.bottom,!0)-n.height*t.scale);var r,h,l=t.longitude,d=t.latitude,c=t.positionOnLine,u=(n=t.imageLabel,this.chart.zoomLevel());if(t.lineId&&(t.line=this.chart.getObjectById(t.lineId)),t.line&&t.line.getCoordinates){t.line.chart=i;var m=t.line.getCoordinates(c,t.lineSegment);m&&(l=i.coordinateToLongitude(m.x),d=i.coordinateToLatitude(m.y),r=m.x,h=m.y,t.animateAngle&&(e=O.radiansToDegrees(m.angle)))}isNaN(e)||s.rotate(e+t.extraAngle),isNaN(a)||isNaN(o)?isNaN(d)||isNaN(l)||(a=(o=i.coordinatesToXY(l,d)).x,o=o.y,isNaN(r)||(a=r),isNaN(h)||(o=h),t.fixedSize?(r=t.positionScale,isNaN(r)?r=0:(--r,r*=1-2*Math.abs(c-.5)),(c=t.objectToResize)&&(c.scale=1+r),s.translate(a,o,1/u+r,!0)):s.translate(a,o,NaN,!0)):s.translate(a,o,NaN,!0),this.positionLabel(n,t,t.labelPositionReal)},positionLabel:function(t,e,i){if(t){var s=0,a=0,o=0,n=0;(r=e.image)&&(n=r.getBBox(),a=r.y+n.y,s=r.x+n.x,o=n.width,n=n.height,e.svgPath&&(o*=e.scale,n*=e.scale));var r,h=(r=t.getBBox()).width,l=r.height;"right"==i&&(s+=o+h/2+5,a+=n/2-2),"left"==i&&(s+=-h/2-5,a+=n/2-2),"top"==i&&(a-=l/2+3,s+=o/2),"bottom"==i&&(a+=n+l/2,s+=o/2),"middle"==i&&(s+=o/2,a+=n/2),t.translate(s+e.labelShiftX,a+e.labelShiftY,NaN,!0),t=e.labelFontSizeReal,e.labelBG&&e.labelBG.translate(s-r.width/2+e.labelShiftX-9,a-t/2+e.labelShiftY-4,NaN,!0)}},createPredefinedImage:function(t,e,i,s,a,o){var n,r=this.chart.container;switch(s){case"circle":n=O.circle(r,a/2,t,1,i,e,1);break;case"rectangle":n=O.polygon(r,[-a/2,a/2,a/2,-a/2],[o/2,o/2,-o/2,-o/2],t,1,i,e,1,0,!0);break;case"bubble":n=O.circle(r,a/2,t,1,i,e,1,!0);break;case"hexagon":a/=Math.sqrt(3),n=O.polygon(r,[.866*a,0*a,-.866*a,-.866*a,0*a,.866*a],[.5*a,1*a,.5*a,-.5*a,-1*a,-.5*a],t,1,i,e,1)}return n},reset:function(){this.objectsToResize=[],this.allSvgObjects=[],this.allObjects=[],this.allLabels=[],this.labelsToReposition=[]}})}(),function(){var e=window.AmCharts;e.ImagesSettings=e.Class({construct:function(t){this.cname="ImagesSettings",this.balloonText="[[title]]",this.alpha=1,this.borderAlpha=0,this.borderThickness=1,this.labelPosition="right",this.labelColor="#000000",this.labelFontSize=11,this.color="#000000",this.labelRollOverColor="#00CC00",this.centered=!0,this.rollOverScale=this.selectedScale=1,this.descriptionWindowWidth=250,this.bringForwardOnHover=!0,this.outlineColor="transparent",this.adjustAnimationSpeed=!1,this.baseAnimationDistance=500,this.pauseDuration=0,this.easingFunction=e.easeInOutQuad,this.animationDuration=3,this.positionScale=1,this.accessibleLabel="[[title]] [[description]]",e.applyTheme(this,t,this.cname)}})}(),function(){var B=window.AmCharts;B.LinesProcessor=B.Class({construct:function(t){this.chart=t,this.reset()},process:function(t){var e,i=t.lines;for(e=0;e<i.length;e++){var s=i[e];this.createLine(s,e),s.parentArray=i}this.counter=e,t.parentObject&&t.remainVisible&&this.process(t.parentObject)},createLine:function(t,e){t=B.processObject(t,B.MapLine),isNaN(e)&&(this.counter++,e=this.counter),t.index=e,t.remove&&t.remove();var i=this.chart,s=i.linesSettings,a=this.objectsToResize,o=i.mapLinesContainer,n=i.stageLinesContainer,r=s.thickness,h=s.dashLength,l=s.arrow,d=s.arrowSize,c=s.arrowColor,u=s.arrowAlpha,m=s.color,p=s.alpha,g=s.rollOverColor,f=s.selectedColor,v=s.rollOverAlpha,b=s.balloonText,N=s.bringForwardOnHover,C=s.arc,w=s.rollOverBrightness,M=i.container;t.chart=i,t.baseSettings=s;var S=M.set();t.displayObject=S;var y=t.tabIndex;if(void 0===y&&(y=s.tabIndex),void 0!==y&&S.setAttr("tabindex",y),this.allSvgObjects.push(S),t.arrays.push({arr:this.allSvgObjects,el:S}),this.allObjects.push(t),t.arrays.push({arr:this.allObjects,el:t}),t.mouseEnabled&&i.addObjectEventListeners(S,t),t.remainVisible||i.selectedObject==t.parentObject){if(y=t.thickness,isNaN(y)&&(y=r),r=t.dashLength,isNaN(r)&&(r=h),null==(h=t.color)&&(h=m),m=t.alpha,isNaN(m)&&(m=p),p=t.rollOverAlpha,isNaN(p)&&(p=v),isNaN(p)&&(p=m),null==(v=t.rollOverColor)&&(v=g),null==(g=t.selectedColor)&&(g=f),void 0===(f=t.balloonText)&&(f=b),b=Number(t.arc),isNaN(b)&&(b=C),(!(C=t.arrow)||"none"==C&&"none"!=l)&&(C=l),null==(l=t.arrowColor)&&(l=c),null==l&&(l=h),c=t.arrowAlpha,isNaN(c)&&(c=u),isNaN(c)&&(c=m),u=t.arrowSize,isNaN(u)&&(u=d),null==(d=t.rollOverBrightness)&&(d=w),t.colorReal=h,t.arrowColor=l,isNaN(s.selectedBrightness)||(g=B.adjustLuminosity(t.colorReal,s.selectedBrightness/100)),t.alphaReal=m,t.rollOverColorReal=v,t.rollOverAlphaReal=p,t.balloonTextReal=f,t.selectedColorReal=g,t.thicknessReal=y,t.rollOverBrightnessReal=d,t.accessibleLabel||(t.accessibleLabel=s.accessibleLabel),void 0===t.shiftArrow&&(t.shiftArrow=s.shiftArrow),null==t.bringForwardOnHover&&(t.bringForwardOnHover=N),B.processDescriptionWindow(s,t),N=this.processCoordinates(t.x,i.realWidth),w=this.processCoordinates(t.y,i.realHeight),d=t.longitudes,s=t.latitudes,0<(p=d.length))for(N=[],w=[],v=0;v<p;v++)f=i.coordinatesToXY(d[v],s[v]),N.push(f.x),w.push(f.y);if(0<N.length){var T,L,x,A,O,z;if(t.segments=N.length,B.dx=0,B.dy=0,10<=(p=10*(1-Math.abs(b)))&&(p=NaN),p<1&&(p=1),t.arcRadius=[],t.distances=[],d=i.mapContainer.scale,isNaN(p)){for(p=0;p<N.length-1;p++)L=Math.sqrt(Math.pow(N[p+1]-N[p],2)+Math.pow(w[p+1]-w[p],2)),t.distances[p]=L;p=B.line(M,N,w,h,1,y/d,r,!1,!1,!0),h=B.line(M,N,w,h,.001,5/d,r,!1,!1,!0),p.setAttr("stroke-linecap","round")}else{f={fill:"none",stroke:h,"stroke-opacity":v=1,"stroke-width":y/d,"fill-opacity":0,"stroke-linecap":"round"},void 0!==r&&0<r&&(f["stroke-dasharray"]=r),r="";for(var k=0;k<N.length-1;k++){var R=N[k],j=N[k+1],I=w[k],D=w[k+1];x=(L=Math.sqrt(Math.pow(j-R,2)+Math.pow(D-I,2)))/2*p,T=270+180*Math.acos(L/2/x)/Math.PI,isNaN(T)&&(T=270),0<b&&(T=-T),r+="M"+R+","+I+"A"+x+","+x+",0,0,"+(v=R<=j?b<0?1:0:0<b?1:0)+","+j+","+D,t.arcRadius[k]=x,t.distances[k]=L}p=M.path(r).attr(f),h=M.path(r).attr({"fill-opacity":0,stroke:h,"stroke-width":5/d,"stroke-opacity":.001,fill:"none"})}B.setCN(i,p,"map-line"),null!=t.id&&B.setCN(i,p,"map-line-"+t.id),B.dx=.5,B.dy=.5,S.push(p),S.push(h),p.setAttr("opacity",m),"none"!=C&&("end"!=C&&"both"!=C||(v=N[N.length-1],k=w[w.length-1],1<N.length?(f=N[N.length-2],A=w[w.length-2]):(f=v,A=k),A=180*Math.atan((k-A)/(v-f))/Math.PI,isNaN(T)||(A+=T),z=k,A=(O=v)-f<0?A-90:A+90),m=[-u/2-.5,-.5,u/2-.5],r=[u,-.5,u],t.shiftArrow&&"middle"!=C&&(r=[0,1.2*-u,0]),"both"==C&&(u=B.polygon(M,m,r,l,c,1,l,c,void 0,!0),S.push(u),u.translate(O,z,1/d,!0),isNaN(A)||u.rotate(A),B.setCN(i,p,"map-line-arrow"),null!=t.id&&B.setCN(i,p,"map-line-arrow-"+t.id),t.fixedSize&&a.push(u)),"start"!=C&&"both"!=C||(u=N[0],z=w[0],1<N.length?(v=N[1],O=w[1]):(v=u,O=z),A=180*Math.atan((z-O)/(u-v))/Math.PI,isNaN(T)||(A-=T),A=(O=u)-v<0?A-90:A+90),"middle"==C&&(v=N[N.length-1],k=w[w.length-1],1<N.length?(f=N[N.length-2],A=w[w.length-2]):(f=v,A=k),O=f+(v-f)/2,z=A+(k-A)/2,A=180*Math.atan2(k-A,v-f)/Math.PI,isNaN(T)||(T=L/2,x-=Math.sqrt(x*x-T*T),f<=v?b<0&&(x=-x):0<b&&(x=-x),O-=Math.sin(A/180*Math.PI)*x,z+=Math.cos(A/180*Math.PI)*x),A+=90),u=B.polygon(M,m,r,l,c,1,l,c,void 0,!0),B.setCN(i,p,"map-line-arrow"),null!=t.id&&B.setCN(i,p,"map-line-arrow-"+t.id),S.push(u),u.translate(O,z,1/d,!0),isNaN(A)||u.rotate(A),t.fixedSize&&(a.push(u),t.arrays.push({arr:a,el:u})),t.arrowSvg=u),t.fixedSize&&p&&(a={line:p,thickness:y},this.linesToResize.push(a),t.arrays.push({arr:this.linesToResize,el:a}),a={line:h,thickness:5},this.linesToResize.push(a),t.arrays.push({arr:this.linesToResize,el:a})),t.lineSvg=p,t.showAsSelected&&!isNaN(g)&&p.setAttr("stroke",g),0<s.length?o.push(S):n.push(S),t.hidden&&S.hide(),i.makeObjectAccessible(t)}}},processCoordinates:function(t,e){var i,s=[];for(i=0;i<t.length;i++){var a=t[i],o=Number(a);isNaN(o)&&(o=Number(a.replace("%",""))*e/100),isNaN(o)||s.push(o)}return s},reset:function(){this.objectsToResize=[],this.allSvgObjects=[],this.allObjects=[],this.linesToResize=[]}})}(),function(){var e=window.AmCharts;e.LinesSettings=e.Class({construct:function(t){this.cname="LinesSettings",this.balloonText="[[title]]",this.thickness=1,this.dashLength=0,this.arrowSize=10,this.arrowAlpha=1,this.arrow="none",this.color="#990000",this.descriptionWindowWidth=250,this.bringForwardOnHover=!0,e.applyTheme(this,t,this.cname)}})}(),function(){var e=window.AmCharts;e.MapObject=e.Class({construct:function(t){this.fixedSize=this.mouseEnabled=!0,this.images=[],this.lines=[],this.areas=[],this.remainVisible=!0,this.passZoomValuesToTarget=!1,this.objectType=this.cname,e.applyTheme(this,t,"MapObject"),this.arrays=[]},deleteObject:function(){if(this.remove(),this.parentArray&&e.removeFromArray(this.parentArray,this),this.arrays)for(var t=0;t<this.arrays.length;t++)e.removeFromArray(this.arrays[t].arr,this.arrays[t].el);this.arrays=[]}})}(),function(){var e=window.AmCharts;e.MapArea=e.Class({inherits:e.MapObject,construct:function(t){this.cname="MapArea",e.MapArea.base.construct.call(this,t),e.applyTheme(this,t,this.cname)},validate:function(){this.chart.areasProcessor.createArea(this)}})}(),function(){var e=window.AmCharts;e.MapLine=e.Class({inherits:e.MapObject,construct:function(t){this.cname="MapLine",this.longitudes=[],this.latitudes=[],this.x=[],this.y=[],this.segments=0,this.arrow="none",e.MapLine.base.construct.call(this,t),e.applyTheme(this,t,this.cname)},validate:function(){this.chart.linesProcessor.createLine(this)},remove:function(){var t=this.displayObject;t&&t.remove()},getCoordinates:function(t,e){if(isNaN(e)&&(e=0),isNaN(this.arc),!isNaN(t)){var i,s,a,o,n,r;if(1<this.longitudes.length){s=this.chart.coordinatesToXY(this.longitudes[e],this.latitudes[e]);var h=this.chart.coordinatesToXY(this.longitudes[e+1],this.latitudes[e+1]);i=s.x,a=h.x,s=s.y,o=h.y}else 1<this.x.length&&(i=this.x[e],a=this.x[e+1],s=this.y[e],o=this.y[e+1]);n=i+(a-i)*t,r=s+(o-s)*t;var l=Math.atan2(o-s,a-i),d=(h=this.arc,10*(1-Math.abs(h)));if(10<=d&&(d=NaN),d<1&&(d=1),!isNaN(h)&&0!==h&&!isNaN(d)){var c=Math.sqrt(Math.pow(a-i,2)+Math.pow(o-s,2));r=c/2*d+.001,l=c/2,d=-Math.sqrt(r*r-l*l),l=180*Math.atan2(o-s,a-i)/Math.PI,i<=a?h<0&&(d=-d):0<h&&(d=-d),n=i+.5*(a-i)-Math.sin(l/180*Math.PI)*d,d=s+.5*(o-s)+Math.cos(l/180*Math.PI)*d,s=(180*Math.atan2(s-d,i-n)/Math.PI+360)%360,(o=(180*Math.atan2(o-d,a-n)/Math.PI+360)%360)<s&&(o+=360),180<o-s&&(s+=360),s=(s+(o-s)*t)/180*Math.PI,l=i<=a?h<0?s+Math.PI/2:s-Math.PI/2:0<h?s+Math.PI/2:s-Math.PI/2,n+=r*Math.cos(s),r=d+r*Math.sin(s)}return this.distance=c,{x:n,y:r,angle:l}}},fixToStage:function(){if(0<this.latitudes.length){this.y=[];for(var t=0;t<this.latitudes.length;t++){var e=this.chart.coordinatesToStageXY(this.longitudes[t],this.latitudes[t]);this.y.push(e.y),this.x.push(e.x)}this.latitudes=[],this.longitudes=[]}this.validate()},fixToMap:function(){if(0<this.y.length){this.latitudes=[];for(var t=0;t<this.y.length;t++){var e=this.chart.stageXYToCoordinates(this.x[t],this.y[t]);this.latitudes.push(e.latitude),this.longitudes.push(e.longitude)}this.y=[],this.x=[]}this.validate()}})}(),function(){var i=window.AmCharts;i.MapImage=i.Class({inherits:i.MapObject,construct:function(t){this.cname="MapImage",this.scale=1,this.widthAndHeightUnits="pixels",this.labelShiftY=this.labelShiftX=0,this.positionOnLine=.5,this.direction=1,this.lineSegment=this.extraAngle=0,this.animateAngle=!0,this.createEvents("animationStart","animationEnd"),i.MapImage.base.construct.call(this,t),i.applyTheme(this,t,this.cname),this.delayCounter=0},validate:function(){this.chart.imagesProcessor.createImage(this)},updatePosition:function(){this.chart.imagesProcessor.updateSizeAndPosition(this)},remove:function(){var t=this.displayObject;t&&t.remove(),(t=this.imageLabel)&&t.remove()},animateTo:function(t,e,i,s){isNaN(i)||(this.animationDuration=i),s&&(this.easingFunction=s),this.finalX=t,this.finalY=e,isNaN(this.longitude)||(this.initialX=this.longitude),isNaN(this.left)||(this.initialX=this.left),isNaN(this.right)||(this.initialX=this.right),isNaN(this.latitude)||(this.initialY=this.latitude),isNaN(this.top)||(this.initialY=this.top),isNaN(this.bottom)||(this.initialY=this.bottom),this.animatingAlong=!1,this.animate()},animateAlong:function(t,e,i){1==this.positionOnLine&&this.flipDirection&&(this.direction=-1,this.extraAngle=180),isNaN(e)||(this.animationDuration=e),i&&(this.easingFunction=i),t&&(this.line=this.chart.getObjectById(t)),this.animateAlongLine=this.line,this.animatingAlong=!0,this.animate()},animate:function(){var t=this.chart.imagesSettings,e=this.animationDuration;isNaN(e)&&(e=t.animationDuration),this.totalFrames=e*i.updateRate,e=1,this.line&&t.adjustAnimationSpeed&&(this.line.distances&&(e=this.line.distances[this.lineSegment]*this.chart.zoomLevel(),e=Math.abs(e/t.baseAnimationDistance)),this.totalFrames=Math.round(e*this.totalFrames)),this.frame=0,this.fire({type:"animationStart",chart:this.chart,image:this,lineSegment:this.lineSegment,direction:this.direction})},update:function(){var t=this.totalFrames;if(this.frame++,this.delayCounter--,0===this.delayCounter&&this.animateAlong(),!(0<this.delayCounter))if(this.frame<=t){var e=this.chart.imagesSettings,i=this.easingFunction;i||(i=e.easingFunction),t=i(0,this.frame,0,1,t),-1==this.direction&&(t=1-t),this.animatingAlong?this.positionOnLine=t:(e=this.initialX+(this.finalX-this.initialX)*t,isNaN(this.longitude)||(this.longitude=e),isNaN(this.left)||(this.left=e),isNaN(this.right)||(this.right=e),t=this.initialY+(this.finalY-this.initialY)*t,isNaN(this.latitude)||(this.latitude=t),isNaN(this.top)||(this.top=t),isNaN(this.bottom)||(this.bottom=t)),this.updatePosition()}else this.frame==t+1&&(this.fire({type:"animationEnd",chart:this.chart,image:this,lineSegment:this.lineSegment,direction:this.direction}),this.line&&this.animatingAlong&&(1==this.direction?this.lineSegment<this.line.segments-2?(this.lineSegment++,this.delayAnimateAlong(),this.positionOnLine=0):this.flipDirection?(this.direction=-1,this.extraAngle=180,this.delayAnimateAlong()):this.loop&&(this.delayAnimateAlong(),this.lineSegment=0):0<this.lineSegment?(this.lineSegment--,this.delayAnimateAlong(),this.positionOnLine=0):this.loop&&this.flipDirection?(this.direction=1,this.extraAngle=0,this.delayAnimateAlong()):this.loop&&this.delayAnimateAlong()))},delayAnimateAlong:function(){this.animateAlongLine&&(this.delayCounter=this.chart.imagesSettings.pauseDuration*i.updateRate)},fixToStage:function(){if(!isNaN(this.longitude)){var t=this.chart.coordinatesToStageXY(this.longitude,this.latitude);this.left=t.x,this.top=t.y,this.latitude=this.longitude=void 0}this.validate()},fixToMap:function(){if(!isNaN(this.left)){var t=this.chart.stageXYToCoordinates(this.left,this.top);this.longitude=t.longitude,this.latitude=t.latitude,this.top=this.left=void 0}this.validate()}})}(),function(){var w=window.AmCharts;w.degreesToRadians=function(t){return t/180*Math.PI},w.radiansToDegrees=function(t){return t/Math.PI*180},w.getColorFade=function(t,e,i){e=(a=w.hex2RGB(e))[0];var s=a[1],a=a[2];t=(n=w.hex2RGB(t))[0];var o=n[1],n=n[2];return"rgb("+(t+=Math.round((e-t)*i))+","+(o+=Math.round((s-o)*i))+","+(n+=Math.round((a-n)*i))+")"},w.hex2RGB=function(t){return[parseInt(t.substring(1,3),16),parseInt(t.substring(3,5),16),parseInt(t.substring(5,7),16)]},w.processDescriptionWindow=function(t,e){isNaN(e.descriptionWindowX)&&(e.descriptionWindowX=t.descriptionWindowX),isNaN(e.descriptionWindowY)&&(e.descriptionWindowY=t.descriptionWindowY),isNaN(e.descriptionWindowLeft)&&(e.descriptionWindowLeft=t.descriptionWindowLeft),isNaN(e.descriptionWindowRight)&&(e.descriptionWindowRight=t.descriptionWindowRight),isNaN(e.descriptionWindowTop)&&(e.descriptionWindowTop=t.descriptionWindowTop),isNaN(e.descriptionWindowBottom)&&(e.descriptionWindowBottom=t.descriptionWindowBottom),isNaN(e.descriptionWindowWidth)&&(e.descriptionWindowWidth=t.descriptionWindowWidth),isNaN(e.descriptionWindowHeight)&&(e.descriptionWindowHeight=t.descriptionWindowHeight)},w.normalizePath=function(t){for(var e,i,s="",a=w.parsePath(t.getAttribute("d")),o=1/0,n=-1/0,r=1/0,h=-1/0,l=0;l<a.length;l++){var d=(u=a[l]).letter,c=u.x,u=u.y;"h"==d&&(d="L",c+=e,u=i),"H"==d&&(d="L",u=i),"v"==d&&(d="L",c=e,u+=i),"V"==d&&(d="L",c=e),"m"!==d&&"l"!==d||(d=d.toUpperCase(),c+=e,u+=i),n<(e=c=w.roundTo(c,3))&&(n=c),c<o&&(o=c),h<(i=u=w.roundTo(u,3))&&(h=u),u<r&&(r=u),s="z"==d.toLowerCase()?s+"Z ":s+(d+" ")+c+" "+u+" "}return t.setAttribute("d",s),{minX:o,maxX:n,minY:r,maxY:h}},w.mercatorLatitudeToRadians=function(t){return Math.log(Math.tan(Math.PI/4+w.degreesToRadians(t)/2))},w.parsePath=function(t){t=t.match(/([MmLlHhVvZz]{1}[0-9.,\-\s]*)/g);for(var e=[],i=0;i<t.length;i++){var s=t[i].match(/([MmLlHhVvZz]{1})|([0-9.\-]+)/g),a={letter:s[0]};switch(s[0]){case"Z":case"Z":case"z":break;case"V":case"v":a.y=Number(s[1]);break;case"H":case"h":a.x=Number(s[1]);break;default:a.x=Number(s[1]),a.y=Number(s[2])}e.push(a)}return e},w.acos=function(t){return 1<t?0:t<-1?Math.PI:Math.acos(t)},w.asin=function(t){return 1<t?Math.PI/2:t<-1?-Math.PI/2:Math.asin(t)},w.sinci=function(t){return t?t/Math.sin(t):1},w.asqrt=function(t){return 0<t?Math.sqrt(t):0},w.winkel3=function(t,e){var i=w.aitoff(t,e);return[(i[0]+t/Math.PI*2)/2,(i[1]+e)/2]},w.winkel3.invert=function(t,e){var i=t,s=e,a=25,o=Math.PI/2;do{var n,r,h,l=Math.cos(s),d=Math.sin(s),c=Math.sin(2*s),u=d*d,m=l*l,p=Math.sin(i),g=Math.cos(i/2),f=Math.sin(i/2),v=f*f,b=(h=1-m*g*g)?w.acos(l*g)*Math.sqrt(n=1/h):n=0,N=.5*(b*d+s)-e,C=.5*n*(m*v+b*l*g*u)+.5/o;i-=r=(N*(r=n*(p*c/4-b*d*f))-(h=.5*(2*b*l*f+i/o)-t)*(u=.5*n*(u*g+b*v*l)+.5))/(l=r*(d=.125*n*(c*f-b*d*m*p))-u*C),s-=h=(h*d-N*C)/l}while((1e-6<Math.abs(r)||1e-6<Math.abs(h))&&0<--a);return[i,s]},w.aitoff=function(t,e){var i=Math.cos(e),s=w.sinci(w.acos(i*Math.cos(t/=2)));return[2*i*Math.sin(t)*s,Math.sin(e)*s]},w.orthographic=function(t,e){return[Math.cos(e)*Math.sin(t),Math.sin(e)]},w.equirectangular=function(t,e){return[t,e]},w.equirectangular.invert=function(t,e){return[t,e]},w.eckert5=function(t,e){var i=Math.PI;return[t*(1+Math.cos(e))/Math.sqrt(2+i),2*e/Math.sqrt(2+i)]},w.eckert5.invert=function(t,e){var i=Math.sqrt(2+Math.PI),s=e*i/2;return[i*t/(1+Math.cos(s)),s]},w.eckert6=function(t,e){for(var i=Math.PI,s=(1+i/2)*Math.sin(e),a=0,o=1/0;a<10&&1e-5<Math.abs(o);a++)e-=o=(e+Math.sin(e)-s)/(1+Math.cos(e));return s=Math.sqrt(2+i),[t*(1+Math.cos(e))/s,2*e/s]},w.eckert6.invert=function(t,e){var i=1+Math.PI/2,s=Math.sqrt(i/2);return[2*t*s/(1+Math.cos(e*=s)),w.asin((e+Math.sin(e))/i)]},w.mercator=function(t,e){return e>=Math.PI/2-.02&&(e=Math.PI/2-.02),e<=-Math.PI/2+.02&&(e=-Math.PI/2+.02),[t,Math.log(Math.tan(Math.PI/4+e/2))]},w.mercator.invert=function(t,e){return[t,2*Math.atan(Math.exp(e))-Math.PI/2]},w.miller=function(t,e){return[t,1.25*Math.log(Math.tan(Math.PI/4+.4*e))]},w.miller.invert=function(t,e){return[t,2.5*Math.atan(Math.exp(.8*e))-.625*Math.PI]},w.eckert3=function(t,e){var i=Math.PI,s=Math.sqrt(i*(4+i));return[2/s*t*(1+Math.sqrt(1-4*e*e/(i*i))),4/s*e]},w.eckert3.invert=function(t,e){var i=Math.PI,s=Math.sqrt(i*(4+i))/2;return[t*s/(1+w.asqrt(1-e*e*(4+i)/(4*i))),e*s/2]}}(),function(){var t=window.AmCharts;t.MapData=t.Class({inherits:t.MapObject,construct:function(){this.cname="MapData",t.MapData.base.construct.call(this),this.projection="mercator",this.topLatitude=90,this.bottomLatitude=-90,this.leftLongitude=-180,this.rightLongitude=180,this.zoomLevel=1,this.getAreasFromMap=!1}})}(),function(){var t=window.AmCharts;t.DescriptionWindow=t.Class({construct:function(){},show:function(t,e,i,s){var a=this;a.chart=t;var o=document.createElement("div");o.style.position="absolute";var n=t.classNamePrefix+"-description-";o.className="ammapDescriptionWindow "+n+"div",a.div=o,e.appendChild(o);var r=".gif";t.svgIcons&&(r=".svg");var h=document.createElement("img");h.className="ammapDescriptionWindowCloseButton "+n+"close-img",h.src=t.pathToImages+"xIcon"+r,h.style.cssFloat="right",h.style.cursor="pointer",h.onclick=function(){a.close()},h.onmouseover=function(){h.src=t.pathToImages+"xIconH"+r},h.onmouseout=function(){h.src=t.pathToImages+"xIcon"+r},o.appendChild(h),(e=document.createElement("div")).className="ammapDescriptionTitle "+n+"title-div",e.onmousedown=function(){a.div.style.zIndex=1e3},o.appendChild(e),e.innerHTML=s,s=e.offsetHeight,(e=document.createElement("div")).className="ammapDescriptionText "+n+"text-div",e.style.maxHeight=a.maxHeight-s-20+"px",o.appendChild(e),e.innerHTML=i},close:function(){try{this.div.parentNode.removeChild(this.div),this.chart.fireClosed()}catch(t){}}})}(),function(){var u=window.AmCharts;u.ValueLegend=u.Class({construct:function(t){this.cname="ValueLegend",this.enabled=!0,this.showAsGradient=!1,this.minValue=0,this.height=12,this.width=200,this.bottom=this.left=10,this.borderColor="#FFFFFF",this.borderAlpha=this.borderThickness=1,this.color="#000000",this.fontSize=11,u.applyTheme(this,t,this.cname)},init:function(t,e){if(this.enabled){var i=t.areasSettings.color,s=t.areasSettings.colorSolid,a=t.colorSteps;u.remove(this.set);var o=e.set();this.set=o,u.setCN(t,o,"value-legend");var n=0,r=this.minValue,h=this.fontSize,l=t.fontFamily,d=this.color,c={precision:t.precision,decimalSeparator:t.decimalSeparator,thousandsSeparator:t.thousandsSeparator};if(null==r&&(r=u.formatNumber(t.minValueReal,c)),void 0!==r&&((n=u.text(e,r,d,l,h,"left")).translate(0,h/2-1),u.setCN(t,n,"value-legend-min-label"),o.push(n),n=n.getBBox().height),void 0===(r=this.maxValue)&&(r=u.formatNumber(t.maxValueReal,c)),void 0!==r&&((n=u.text(e,r,d,l,h,"right")).translate(this.width,h/2-1),u.setCN(t,n,"value-legend-max-label"),o.push(n),n=n.getBBox().height),this.showAsGradient)i=u.rect(e,this.width,this.height,[i,s],1,this.borderThickness,this.borderColor,1,0,0),u.setCN(t,i,"value-legend-gradient"),i.translate(0,n),o.push(i);else for(h=this.width/a,l=0;l<a;l++)d=u.getColorFade(i,s,1*l/(a-1)),d=u.rect(e,h,this.height,d,1,this.borderThickness,this.borderColor,1),u.setCN(t,d,"value-legend-color"),u.setCN(t,d,"value-legend-color-"+l),d.translate(h*l,n),o.push(d);s=i=0,a=o.getBBox(),n=t.getY(this.bottom,!0),h=t.getY(this.top),l=t.getX(this.right,!0),d=t.getX(this.left),isNaN(h)||(i=h),isNaN(n)||(i=n-a.height),isNaN(d)||(s=d),isNaN(l)||(s=l-a.width),o.translate(s,i)}else u.remove(this.set)}})}(),function(){var t=window.AmCharts;t.ObjectList=t.Class({construct:function(t){this.divId=t},init:function(t){this.chart=t;var e=this.divId;this.container&&(e=this.container),this.div="object"!=typeof e?document.getElementById(e):e,(e=document.createElement("div")).className="ammapObjectList "+t.classNamePrefix+"-object-list-div",this.div.appendChild(e),this.addObjects(t.dataProvider,e)},addObjects:function(t,e){var i,s=this.chart,a=document.createElement("ul");if(a.className=s.classNamePrefix+"-object-list-ul",t.areas)for(i=0;i<t.areas.length;i++){var o=t.areas[i];void 0===o.showInList&&(o.showInList=s.showAreasInList),this.addObject(o,a)}if(t.images)for(i=0;i<t.images.length;i++)void 0===(o=t.images[i]).showInList&&(o.showInList=s.showImagesInList),this.addObject(o,a);if(t.lines)for(i=0;i<t.lines.length;i++)void 0===(o=t.lines[i]).showInList&&(o.showInList=s.showLinesInList),this.addObject(o,a);0<a.childNodes.length&&e.appendChild(a)},addObject:function(t,e){var i=this;if(t.showInList&&void 0!==t.title){var s=i.chart,a=document.createElement("li");a.className=s.classNamePrefix+"-object-list-li",(o=t.titleTr)||(o=t.title);var o=document.createTextNode(o),n=document.createElement("a");n.className=s.classNamePrefix+"-object-list-a",n.appendChild(o),a.appendChild(n),e.appendChild(a),this.addObjects(t,a),n.onmouseover=function(){i.chart.rollOverMapObject(t,!1)},n.onmouseout=function(){i.chart.rollOutMapObject(t)},n.onclick=function(){i.chart.clickMapObject(t)}}}})}();