(function () { var script = document.getElementById('highcharts-script'); function addChart() { function parseData(completeHandler, chartOptions) { try { var dataOptions = { "seriesMapping": [ { "x": 0 }, { "x": 0 }, { "x": 0 } ], "columnTypes": [ "string", "float", "float", "float" ], "csv": ",heute,1 Monat,EZB-Einlagezins\n6M,-0.68,-0.58,-0.4\n1J,-0.64,-0.53,-0.4\n2J,-0.67,-0.54,-0.4\n3J,-0.69,-0.53,-0.4\n4J,-0.66,-0.48,-0.4\n5J,-0.61,-0.42,-0.4\n6J,-0.56,-0.34,-0.4\n7J,-0.48,-0.29,-0.4\n8J,-0.37,-0.19,-0.4\n9J,-0.24,-0.01,-0.4\n10J,-0.16,0.04,-0.4\n15J,0,0.25,-0.4\n20J,0.2,0.46,-0.4\n30J,0.38,0.64,-0.4" }; dataOptions.sort = true dataOptions.complete = completeHandler; Highcharts.data(dataOptions, chartOptions); } catch (error) { console.log(error); completeHandler(undefined); } } var shareUrl = 'https://app.everviz.com/show/exoxiq'; var encodedUrl = encodeURIComponent(shareUrl); var template = { chart: { renderTo: 'highcharts-exoxiq' }, navigation: { menuItemStyle: { fontFamily: Highcharts.SVGRenderer.prototype.getStyle().fontFamily, padding: '2px 10px' } }, exporting: { buttons: { contextButton: { menuItems: [{ text: '' + 'Share on Facebook' }, { text: '' + 'Share on Google+' }, { text: '' + 'Share on Twitter' }, { text: '' + 'Share on LinkedIn' }, { separator: true }] .concat(Highcharts.getOptions().exporting.buttons.contextButton.menuItems) .concat([{ separator: true }, { text: '' + 'Edit chart' }, { text: '' + 'Create chart' }]) } } } }; var chartOptions = { "yAxis": { "title": { "text": null } }, "exporting": { "enabled": false }, "credits": { "branded": true, "text": "Highcharts", "href": "//app.everviz.com/", "enabled": true }, "series": [ { "color": "#aa5888", "marker": { "enabled": false }, "tooltip": { "valueSuffix": "%" }, "index": 0, "negativeColor": "#aa5888", "type": "line" }, { "marker": { "enabled": false }, "tooltip": { "valueSuffix": "%" }, "index": 1 }, { "color": "#4a3333", "dashStyle": "ShortDash", "marker": { "enabled": false }, "tooltip": { "valueSuffix": "%" }, "index": 2, "negativeColor": "#684545", "type": "line" } ], "tooltip": { "shared": true }, "title": { "style": { "fontWeight": "bold", "fontSize": "0px" }, "text": "Zinskurve Deutschland" }, "chart": { "style": { "fontFamily": "Arial" }, "type": "line", "height": 450 }, "colors": [ "#7cb5ec", "#434348", "#90ed7d", "#f7a35c", "#8085e9", "#f15c80", "#e4d354", "#2b908f", "#f45b5b", "#91e8e1" ] }; parseData(function (dataOptions) { // Merge series configs if (chartOptions.series && dataOptions) { Highcharts.each(chartOptions.series, function (series, i) { chartOptions.series[i] = Highcharts.merge(series, dataOptions.series[i]); }); } var options = Highcharts.merge(dataOptions, chartOptions, template); var chart = new Highcharts['Chart'](options); }, chartOptions); } // Load the Highcharts script if undefined, and add the chart if (typeof Highcharts !== 'undefined') { addChart(); } else if (script) { script.deferredCharts.push(addChart); } else { script = document.createElement('script'); script.id = 'highcharts-script'; script.src = '//app.everviz.com/resources/js/highstock-cloud-5.0.7.js'; script.type = 'text/javascript'; script.deferredCharts = [addChart]; script.onload = function () { // Prevent double firing of event in IE9/IE10 if (!script.chartsAdded) { script.chartsAdded = true; while(script.deferredCharts.length) { script.deferredCharts.shift()(); } } }; script.onreadystatechange = function() { if (this.readyState == 'complete' || this.readyState == 'loaded') { script.onload(); } }; document.getElementsByTagName('head')[0].appendChild(script); } }());