var temp = [10.6,10.5,10.5,10.7,10.7,10.8,11,11.5,11.8,12.7,13,13.9,14.5]; var temptime = ['02.50','03.20','03.50','04.20','04.50','05.20','05.50','06.20','06.50','07.20','07.50','08.20','08.50']; var rain = [0.2,0.2,0.5,0.5,0.5,0.7,0.7,0.7,0.7,0.7,13.5,13.5,13.5]; var raintime = ['02.50','03.20','03.50','04.20','04.50','05.20','05.50','06.20','06.50','07.20','07.50','08.20','08.50']; var wind = [5,5,5,5,5,5,5,5,5,5,5,5,5]; var windtime = ['06.50','07.00','07.10','07.20','07.30','07.40','07.50','08.00','08.10','08.20','08.30','08.40','08.50']; var solar = [0,0,0,0,0,0,0,0,12,47,207,325,485]; var solartime = ['20.50','21.50','22.50','23.50','00.50','01.50','02.50','03.50','04.50','05.50','06.50','07.50','08.50']; var baro = [1011.3,1012.4,1012.1,1012.2,1012.9,1013.6,1014.3,1014.5,1015.1,1015.4,1015.9,1016.6,1016.9]; var barotime = ['20.50','21.50','22.50','23.50','00.50','01.50','02.50','03.50','04.50','05.50','06.50','07.50','08.50']; $(function() { $('.windd').sparkline([340,20], { type: 'pie', sliceColors: ['#5B7102','#ffffff'], offset: 247, chartRangeMin: 0, chartRangeMax: 360, borderWidth: 1, borderColor: '#ffffff', tooltipClassname: 'spark', tooltipPrefix:'Bearing: 327', tooltipSuffix: '°', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipChartTitle: 'Avg. Wind Dir.' + '
' + ' Last 3 hours' }); }); $(function() { $('.temp').sparkline(temptime, { type: 'line', lineColor: '#5B7102', fillColor: '#5B7102', spotColor: '#5B7102', minSpotColor: '#5B7102', maxSpotColor: '#5B7102', numberFormatter: function(y) {return (('0000'+(y.toFixed(2))).slice (-5));}, width: 60, height:16, tooltipClassname: 'spark', tooltipPrefix: 'Time: ', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipChartTitle: 'Temperature Today.' }); $('.temp').sparkline(temp, { composite: true, type: 'line', lineColor: '#ffffff', fillColor: '#5B7102', spotColor: '#ffffff', minSpotColor: '#55a9fd', maxSpotColor: '#f23434', tooltipClassname: 'spark', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Temp: ', tooltipSuffix: " °C", width: 60, height:16 }); }); $(function() { $('.wind').sparkline(windtime, { type: 'line', lineColor: '#5B7102', fillColor: '#5B7102', spotColor: '#5B7102', minSpotColor: '#5B7102', maxSpotColor: '#5B7102', numberFormatter: function(y) {return (('0000'+(y.toFixed(2))).slice (-5));}, width: 60, height:16, tooltipClassname: 'spark', tooltipChartTitle: 'Wind Speed Today.', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Time: ' }); $('.wind').sparkline(wind, { composite: true, type: 'line', lineColor: '#ffffff', fillColor: '#5B7102', spotColor: '#ffffff', minSpotColor: '#55a9fd', maxSpotColor: '#f23434', tooltipClassname: 'spark', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Wind: ', tooltipSuffix: " kts", width: 60, height:16 }); }); $(function() { $('.rain').sparkline(raintime, { type: 'line', lineColor: '#5B7102', fillColor: '#5B7102', spotColor: '#5B7102', minSpotColor: '#5B7102', maxSpotColor: '#5B7102', numberFormatter: function(y) {return (('0000'+(y.toFixed(2))).slice (-5));}, width: 60, height:16, tooltipClassname: 'spark', tooltipPrefix: 'Time: ', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipChartTitle: 'Rainfall Today.' }); $('.rain').sparkline(rain, { composite: true, type: 'line', lineColor: '#ffffff', fillColor: '#5B7102', spotColor: '#ffffff', minSpotColor: '#55a9fd', maxSpotColor: '#f23434', tooltipClassname: 'spark', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Rain: ', tooltipSuffix: " mm", width: 60, height:16 }); }); $(function() { $('.solar').sparkline(solartime, { type: 'line', lineColor: '#5B7102', fillColor: '#5B7102', spotColor: '#5B7102', minSpotColor: '#5B7102', maxSpotColor: '#5B7102', numberFormatter: function(y) {return (('0000'+(y.toFixed(2))).slice (-5));}, width: 60, height:16, tooltipClassname: 'spark', tooltipChartTitle: 'Solar Today.', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Time: ' }); $('.solar').sparkline(solar, { composite: true, type: 'line', lineColor: '#ffffff', fillColor: '#5B7102', spotColor: '#ffffff', minSpotColor: '#55a9fd', maxSpotColor: '#f23434', tooltipClassname: 'spark', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Sun: ', tooltipSuffix: " w/m²", width: 60, height:16 }); }); $(function() { $('.baro').sparkline(barotime, { type: 'line', lineColor: '#5B7102', fillColor: '#5B7102', spotColor: '#5B7102', minSpotColor: '#5B7102', maxSpotColor: '#5B7102', numberFormatter: function(y) {return (('0000'+(y.toFixed(2))).slice (-5));}, width: 60, height:16, tooltipClassname: 'spark', tooltipChartTitle: 'Barometer Today.', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Time: ' }); $('.baro').sparkline(baro, { composite: true, type: 'line', lineColor: '#ffffff', fillColor: '#5B7102', spotColor: '#ffffff', minSpotColor: '#55a9fd', maxSpotColor: '#f23434', numberDigitGroupCount: 6, tooltipClassname: 'spark', tooltipFormat:'{{prefix}}{{y}}{{suffix}}', tooltipPrefix: 'Baro: ', tooltipSuffix: " mb", width: 60, height:16 }); });