var graphs = {}; $(document).ready(function() { dataset = [ { label: 'Teplota (°C)', data: [[1787954400000,14.06666667],[1787954580000,13.88000000],[1787954880000,13.70000000],[1787955180000,13.76000000],[1787955480000,13.54000000],[1787955780000,13.50000000],[1787956080000,13.64000000],[1787956380000,13.78000000],[1787956680000,13.60000000],[1787956980000,13.50000000],[1787957280000,13.50000000],[1787957580000,13.48000000],[1787957880000,13.46000000],[1787958180000,13.44000000],[1787958480000,13.54000000],[1787958780000,13.60000000],[1787959080000,13.60000000],[1787959380000,13.60000000],[1787959680000,13.60000000],[1787959980000,13.38000000],[1787960280000,13.38000000],[1787960580000,13.46000000],[1787960880000,13.28000000],[1787961180000,13.16000000],[1787961480000,13.02000000],[1787961780000,13.00000000],[1787962080000,13.00000000],[1787962380000,13.08000000],[1787962680000,13.18000000],[1787962980000,13.30000000],[1787963280000,13.42000000],[1787963580000,13.50000000],[1787963880000,13.52000000],[1787964180000,13.68000000],[1787964480000,14.00000000],[1787964780000,14.22000000],[1787965080000,14.30000000],[1787965380000,14.24000000],[1787965680000,14.10000000],[1787965980000,14.10000000],[1787966280000,14.22000000],[1787966580000,14.38000000],[1787966880000,14.40000000],[1787967180000,14.48000000],[1787967480000,14.40000000],[1787967780000,14.24000000],[1787968080000,14.20000000],[1787968380000,14.26000000],[1787968680000,14.30000000],[1787968980000,14.28000000],[1787969280000,14.26000000],[1787969580000,14.30000000],[1787969880000,14.36000000],[1787970180000,14.34000000],[1787970480000,14.70000000],[1787970780000,15.08000000],[1787971080000,15.10000000],[1787971380000,15.22000000],[1787971680000,15.22000000],[1787971980000,15.20000000],[1787972280000,15.46000000],[1787972580000,15.94000000],[1787972880000,16.42000000],[1787973180000,16.50000000],[1787973480000,16.46000000],[1787973780000,16.34000000],[1787974080000,16.22000000],[1787974380000,16.10000000],[1787974680000,16.10000000],[1787974980000,16.10000000],[1787975280000,16.06000000],[1787975580000,16.00000000],[1787975880000,15.98000000],[1787976180000,15.90000000],[1787976480000,15.78000000],[1787976780000,15.70000000],[1787977080000,15.60000000],[1787977380000,15.50000000],[1787977680000,15.46000000],[1787977980000,15.40000000],], color: '#d6212a' }, { label: 'Rosný bod (°C)', data: [[1787954400000,10.7],[1787954580000,10.7],[1787954880000,10.7],[1787955180000,10.6],[1787955480000,10.7],[1787955780000,10.6],[1787956080000,10.7],[1787956380000,10.8],[1787956680000,10.9],[1787956980000,10.8],[1787957280000,10.7],[1787957580000,10.7],[1787957880000,10.8],[1787958180000,10.9],[1787958480000,10.7],[1787958780000,10.7],[1787959080000,10.7],[1787959380000,10.7],[1787959680000,10.6],[1787959980000,10.7],[1787960280000,10.7],[1787960580000,10.8],[1787960880000,10.8],[1787961180000,10.8],[1787961480000,10.7],[1787961780000,10.7],[1787962080000,10.7],[1787962380000,11],[1787962680000,11],[1787962980000,11],[1787963280000,11],[1787963580000,11],[1787963880000,10.8],[1787964180000,10.7],[1787964480000,10.7],[1787964780000,10.8],[1787965080000,11],[1787965380000,11.1],[1787965680000,10.9],[1787965980000,11],[1787966280000,10.9],[1787966580000,11],[1787966880000,11],[1787967180000,10.9],[1787967480000,11.2],[1787967780000,11.1],[1787968080000,11],[1787968380000,11.1],[1787968680000,11.2],[1787968980000,11.2],[1787969280000,11.3],[1787969580000,11.3],[1787969880000,11.3],[1787970180000,11.2],[1787970480000,10.8],[1787970780000,10.9],[1787971080000,11.1],[1787971380000,10.7],[1787971680000,11.1],[1787971980000,11.1],[1787972280000,10.9],[1787972580000,11.9],[1787972880000,12.6],[1787973180000,12.8],[1787973480000,13],[1787973780000,13],[1787974080000,13.1],[1787974380000,13.1],[1787974680000,13.1],[1787974980000,13.2],[1787975280000,13.2],[1787975580000,13.2],[1787975880000,13.3],[1787976180000,13.3],[1787976480000,13.4],[1787976780000,13.5],[1787977080000,13.5],[1787977380000,13.5],[1787977680000,13.6],[1787977980000,13.6],], color: '#5b9f4a' } ]; var options = { xaxes: [{ axisLabel: 'temperature', }], points: { show: false }, lines: { show: true, lineWidth: 2, fill: false, }, xaxis: { mode: 'time', minTickSize: [1, 'hour'], timeformat: '%d.%m.\, %H:%M', timezone: 'browser', }, grid: { hoverable: true, clickable: true, borderWidth: 0, }, tooltip: { show: true, content: '%x - %y.1°C' }, crosshair: { mode: 'x' }, legend: { show: true, container: '#chart-temperature-legend' } }; graphs['#chart-temperature'] = $.plot('#chart-temperature', dataset, options); }); $(document).ready(function() { var dataset = [{label: "5 cm nad povrchom (\u00b0C)", data: [[1787954400000,11.70000000],[1787954580000,11.70000000],[1787954880000,11.86000000],[1787955180000,12.04000000],[1787955480000,12.14000000],[1787955780000,12.20000000],[1787956080000,12.36000000],[1787956380000,12.42000000],[1787956680000,12.32000000],[1787956980000,12.24000000],[1787957280000,12.18000000],[1787957580000,12.02000000],[1787957880000,12.02000000],[1787958180000,12.04000000],[1787958480000,12.10000000],[1787958780000,12.14000000],[1787959080000,12.10000000],[1787959380000,12.10000000],[1787959680000,12.10000000],[1787959980000,12.00000000],[1787960280000,12.04000000],[1787960580000,12.04000000],[1787960880000,11.90000000],[1787961180000,11.74000000],[1787961480000,11.62000000],[1787961780000,11.50000000],[1787962080000,11.66000000],[1787962380000,12.16000000],[1787962680000,12.64000000],[1787962980000,12.92000000],[1787963280000,12.84000000],[1787963580000,12.86000000],[1787963880000,12.96000000],[1787964180000,13.18000000],[1787964480000,13.58000000],[1787964780000,13.86000000],[1787965080000,13.90000000],[1787965380000,13.54000000],[1787965680000,13.12000000],[1787965980000,13.28000000],[1787966280000,13.50000000],[1787966580000,13.72000000],[1787966880000,13.72000000],[1787967180000,13.58000000],[1787967480000,13.24000000],[1787967780000,13.12000000],[1787968080000,13.30000000],[1787968380000,13.48000000],[1787968680000,13.56000000],[1787968980000,13.60000000],[1787969280000,13.70000000],[1787969580000,13.70000000],[1787969880000,13.68000000],[1787970180000,13.38000000],[1787970480000,13.72000000],[1787970780000,14.12000000],[1787971080000,14.44000000],[1787971380000,14.58000000],[1787971680000,14.16000000],[1787971980000,14.16000000],[1787972280000,14.02000000],[1787972580000,14.14000000],[1787972880000,14.62000000],[1787973180000,14.82000000],[1787973480000,14.90000000],[1787973780000,14.96000000],[1787974080000,15.00000000],[1787974380000,15.00000000],[1787974680000,15.10000000],[1787974980000,15.06000000],[1787975280000,15.00000000],[1787975580000,15.00000000],[1787975880000,15.00000000],[1787976180000,15.06000000],[1787976480000,15.10000000],[1787976780000,15.14000000],[1787977080000,15.20000000],[1787977380000,15.20000000],[1787977680000,15.20000000],[1787977980000,15.20000000],], color: "#f39c12"}]; var options = { points: { show: false }, lines: { show: true, lineWidth: 2, fill: false }, xaxis: { mode: 'time', minTickSize: [1, 'hour'], timeformat: '%d.%m.\, %H:%M', timezone: 'browser' }, grid: { hoverable: true, clickable: true, borderWidth: 0 }, tooltip: { show: true, content: '%x - %y.1°C' }, crosshair: { mode: 'x' }, legend: { show: true, container: '#chart-ground-temperature-legend' } }; graphs['#chart-ground-temperature'] = $.plot('#chart-ground-temperature', dataset, options); }); $(document).ready(function() { dataset = [ { label: 'Vlhkosť (%)', data: [[1787954400000,80.56666667],[1787954580000,81.44000000],[1787954880000,81.98000000],[1787955180000,81.48000000],[1787955480000,82.88000000],[1787955780000,82.56000000],[1787956080000,82.44000000],[1787956380000,82.26000000],[1787956680000,84.14000000],[1787956980000,83.70000000],[1787957280000,83.26000000],[1787957580000,83.48000000],[1787957880000,84.18000000],[1787958180000,84.62000000],[1787958480000,83.24000000],[1787958780000,82.68000000],[1787959080000,82.76000000],[1787959380000,82.62000000],[1787959680000,82.22000000],[1787959980000,84.08000000],[1787960280000,83.92000000],[1787960580000,83.98000000],[1787960880000,84.98000000],[1787961180000,85.46000000],[1787961480000,85.92000000],[1787961780000,86.00000000],[1787962080000,86.22000000],[1787962380000,87.12000000],[1787962680000,86.70000000],[1787962980000,85.82000000],[1787963280000,85.20000000],[1787963580000,85.06000000],[1787963880000,83.80000000],[1787964180000,82.32000000],[1787964480000,80.46000000],[1787964780000,80.28000000],[1787965080000,80.52000000],[1787965380000,81.52000000],[1787965680000,81.48000000],[1787965980000,81.50000000],[1787966280000,80.78000000],[1787966580000,80.14000000],[1787966880000,80.16000000],[1787967180000,79.40000000],[1787967480000,81.30000000],[1787967780000,81.70000000],[1787968080000,81.42000000],[1787968380000,81.38000000],[1787968680000,81.68000000],[1787968980000,82.02000000],[1787969280000,82.30000000],[1787969580000,82.22000000],[1787969880000,82.08000000],[1787970180000,81.62000000],[1787970480000,77.58000000],[1787970780000,76.30000000],[1787971080000,77.14000000],[1787971380000,74.82000000],[1787971680000,76.58000000],[1787971980000,76.64000000],[1787972280000,74.40000000],[1787972580000,76.88000000],[1787972880000,78.22000000],[1787973180000,79.08000000],[1787973480000,79.92000000],[1787973780000,80.90000000],[1787974080000,81.98000000],[1787974380000,82.70000000],[1787974680000,82.66000000],[1787974980000,82.86000000],[1787975280000,83.44000000],[1787975580000,83.80000000],[1787975880000,84.14000000],[1787976180000,84.84000000],[1787976480000,85.72000000],[1787976780000,86.64000000],[1787977080000,87.60000000],[1787977380000,88.24000000],[1787977680000,88.70000000],[1787977980000,88.96666667],], color: '#ff9000' } ]; var options = { xaxes: [{ axisLabel: 'humidity', }], points: { show: false }, lines: { show: true, lineWidth: 2, fill: false, }, xaxis: { mode: 'time', minTickSize: [1, 'hour'], timeformat: '%d.%m.\, %H:%M', timezone: 'browser', }, grid: { hoverable: true, clickable: true, borderWidth: 0, }, tooltip: { show: true, content: '%x - %y.1%' }, crosshair: { mode: 'x' }, legend: { show: true, container: '#chart-humidity-legend' } }; graphs['#chart-humidity'] = $.plot('#chart-humidity', dataset, options); }); $(document).ready(function() { dataset = [ { label: 'Rýchlosť vetra (km/h)', data: [[1787954400000,2.16],[1787954580000,3.096],[1787954880000,1.44],[1787955180000,2.376],[1787955480000,1.656],[1787955780000,3.24],[1787956080000,4.536],[1787956380000,0.936],[1787956680000,1.8],[1787956980000,2.088],[1787957280000,0.936],[1787957580000,1.44],[1787957880000,2.088],[1787958180000,2.664],[1787958480000,2.736],[1787958780000,1.944],[1787959080000,3.6],[1787959380000,3.744],[1787959680000,2.232],[1787959980000,3.096],[1787960280000,3.384],[1787960580000,1.368],[1787960880000,1.296],[1787961180000,1.584],[1787961480000,1.872],[1787961780000,1.368],[1787962080000,2.304],[1787962380000,3.384],[1787962680000,3.96],[1787962980000,3.744],[1787963280000,3.312],[1787963580000,4.536],[1787963880000,4.968],[1787964180000,4.392],[1787964480000,3.888],[1787964780000,3.24],[1787965080000,1.368],[1787965380000,3.096],[1787965680000,4.32],[1787965980000,3.672],[1787966280000,2.736],[1787966580000,1.728],[1787966880000,2.88],[1787967180000,2.88],[1787967480000,4.464],[1787967780000,3.96],[1787968080000,2.592],[1787968380000,1.944],[1787968680000,3.384],[1787968980000,3.096],[1787969280000,3.24],[1787969580000,2.448],[1787969880000,5.616],[1787970180000,10.08],[1787970480000,6.624],[1787970780000,5.328],[1787971080000,3.24],[1787971380000,2.448],[1787971680000,5.76],[1787971980000,3.672],[1787972280000,6.912],[1787972580000,11.592],[1787972880000,10.512],[1787973180000,10.368],[1787973480000,11.808],[1787973780000,10.512],[1787974080000,9.648],[1787974380000,11.016],[1787974680000,12.384],[1787974980000,6.984],[1787975280000,7.272],[1787975580000,8.712],[1787975880000,9.216],[1787976180000,8.928],[1787976480000,10.44],[1787976780000,8.064],[1787977080000,10.296],[1787977380000,11.088],[1787977680000,9.864],[1787977980000,8.520000012],], color: '#002f80', points: { show: false }, lines: { show: true, lineWidth: 2, fill: false, }, }, { label: 'Náraz vetra (km/h)', data: [[1787954400000,2.760000012],[1787954580000,4.68],[1787954880000,2.376],[1787955180000,3.096],[1787955480000,2.232],[1787955780000,4.104],[1787956080000,5.472],[1787956380000,1.656],[1787956680000,2.16],[1787956980000,2.448],[1787957280000,1.44],[1787957580000,1.728],[1787957880000,3.024],[1787958180000,3.528],[1787958480000,3.888],[1787958780000,2.952],[1787959080000,5.112],[1787959380000,5.328],[1787959680000,3.384],[1787959980000,3.744],[1787960280000,4.392],[1787960580000,1.872],[1787960880000,1.944],[1787961180000,2.016],[1787961480000,2.232],[1787961780000,1.656],[1787962080000,3.168],[1787962380000,4.248],[1787962680000,5.328],[1787962980000,5.328],[1787963280000,4.392],[1787963580000,5.904],[1787963880000,7.056],[1787964180000,6.048],[1787964480000,5.112],[1787964780000,4.32],[1787965080000,2.16],[1787965380000,3.96],[1787965680000,5.112],[1787965980000,4.824],[1787966280000,3.888],[1787966580000,2.592],[1787966880000,3.888],[1787967180000,3.96],[1787967480000,5.472],[1787967780000,6.336],[1787968080000,3.816],[1787968380000,2.808],[1787968680000,4.464],[1787968980000,3.816],[1787969280000,4.248],[1787969580000,3.744],[1787969880000,7.92],[1787970180000,14.4],[1787970480000,10.152],[1787970780000,7.704],[1787971080000,4.968],[1787971380000,3.744],[1787971680000,7.848],[1787971980000,7.272],[1787972280000,11.16],[1787972580000,19.728],[1787972880000,17.712],[1787973180000,16.272],[1787973480000,17.64],[1787973780000,17.568],[1787974080000,16.92],[1787974380000,16.848],[1787974680000,19.224],[1787974980000,10.872],[1787975280000,12.888],[1787975580000,13.968],[1787975880000,14.256],[1787976180000,12.672],[1787976480000,16.632],[1787976780000,13.104],[1787977080000,18.144],[1787977380000,17.568],[1787977680000,14.184],[1787977980000,14.76],], color: '#EF9856', points: { show: true }, lines: { show: false }, } ]; var options = { xaxes: [{ axisLabel: 'wind', }], xaxis: { mode: 'time', minTickSize: [1, 'hour'], timeformat: '%d.%m.\, %H:%M', timezone: 'browser', }, grid: { hoverable: true, clickable: true, borderWidth: 0, }, tooltip: { show: true, content: '%x - %y.1km/h' }, crosshair: { mode: 'x' }, legend: { show: true, container: '#chart-wind-legend' } }; graphs['#chart-wind'] = $.plot('#chart-wind', dataset, options); }); $(document).ready(function() { dataset = [ { label: 'Smer vetra', data: [[1787954400000,299.06666667],[1787954580000,246.88000000],[1787954880000,105.66000000],[1787955180000,164.90000000],[1787955480000,200.12000000],[1787955780000,269.10000000],[1787956080000,148.86000000],[1787956380000,252.50000000],[1787956680000,165.62000000],[1787956980000,74.14000000],[1787957280000,183.14000000],[1787957580000,301.54000000],[1787957880000,292.14000000],[1787958180000,260.24000000],[1787958480000,86.44000000],[1787958780000,331.74000000],[1787959080000,330.12000000],[1787959380000,326.70000000],[1787959680000,309.62000000],[1787959980000,292.06000000],[1787960280000,266.32000000],[1787960580000,176.26000000],[1787960880000,153.08000000],[1787961180000,195.22000000],[1787961480000,126.98000000],[1787961780000,116.78000000],[1787962080000,247.44000000],[1787962380000,313.76000000],[1787962680000,303.78000000],[1787962980000,339.00000000],[1787963280000,302.68000000],[1787963580000,279.70000000],[1787963880000,297.16000000],[1787964180000,333.94000000],[1787964480000,26.74000000],[1787964780000,116.60000000],[1787965080000,193.78000000],[1787965380000,284.22000000],[1787965680000,285.24000000],[1787965980000,332.72000000],[1787966280000,333.34000000],[1787966580000,99.22000000],[1787966880000,63.42000000],[1787967180000,166.60000000],[1787967480000,293.54000000],[1787967780000,299.48000000],[1787968080000,128.44000000],[1787968380000,31.38000000],[1787968680000,43.82000000],[1787968980000,226.56000000],[1787969280000,333.56000000],[1787969580000,279.10000000],[1787969880000,306.78000000],[1787970180000,319.42000000],[1787970480000,340.50000000],[1787970780000,85.42000000],[1787971080000,41.76000000],[1787971380000,147.44000000],[1787971680000,301.10000000],[1787971980000,306.74000000],[1787972280000,302.80000000],[1787972580000,318.64000000],[1787972880000,327.90000000],[1787973180000,326.02000000],[1787973480000,325.74000000],[1787973780000,329.38000000],[1787974080000,335.18000000],[1787974380000,323.52000000],[1787974680000,310.22000000],[1787974980000,315.58000000],[1787975280000,317.10000000],[1787975580000,321.42000000],[1787975880000,318.18000000],[1787976180000,308.88000000],[1787976480000,311.26000000],[1787976780000,315.56000000],[1787977080000,326.64000000],[1787977380000,303.98000000],[1787977680000,314.62000000],[1787977980000,307.66666667],], color: '#002f80', points: { show: true }, lines: { show: false }, } ]; var options = { xaxes: [{ axisLabel: 'wind_direction', }], xaxis: { mode: 'time', minTickSize: [1, 'hour'], timeformat: '%d.%m.\, %H:%M', timezone: 'browser', }, yaxis: { min: 0, max: 360, ticks: [[0, 'S'], [90, 'V'], [180, 'J'], [270, 'Z'], [360, 'S']] }, grid: { hoverable: true, clickable: true, borderWidth: 0, }, tooltip: { show: true, content: function(label, xval, yval, flotItem) { dir = meteo_wind_direction_name(yval); format_date = moment(xval).format('DD.MM., hh:mm') return format_date+' - '+dir; } }, crosshair: { mode: 'x' }, legend: { show: true, container: '#chart-wind-direction-legend' } }; graphs['#chart-wind-direction'] = $.plot('#chart-wind-direction', dataset, options); }); $(document).ready(function() { dataset = [ { label: 'Zrážky', data: [[1787954400000,0],[1787954580000,0],[1787954880000,0],[1787955180000,0],[1787955480000,0],[1787955780000,0],[1787956080000,0],[1787956380000,0],[1787956680000,0],[1787956980000,0],[1787957280000,0],[1787957580000,0],[1787957880000,0],[1787958180000,0],[1787958480000,0],[1787958780000,0],[1787959080000,0],[1787959380000,0],[1787959680000,0],[1787959980000,0],[1787960280000,0],[1787960580000,0],[1787960880000,0],[1787961180000,0],[1787961480000,0],[1787961780000,0],[1787962080000,0],[1787962380000,0],[1787962680000,0],[1787962980000,0],[1787963280000,0],[1787963580000,0],[1787963880000,0],[1787964180000,0],[1787964480000,0],[1787964780000,0],[1787965080000,0],[1787965380000,0],[1787965680000,0],[1787965980000,0],[1787966280000,0],[1787966580000,0],[1787966880000,0],[1787967180000,0],[1787967480000,0],[1787967780000,0],[1787968080000,0],[1787968380000,0],[1787968680000,0],[1787968980000,0],[1787969280000,0],[1787969580000,0],[1787969880000,0],[1787970180000,0],[1787970480000,0],[1787970780000,0],[1787971080000,0],[1787971380000,0],[1787971680000,0],[1787971980000,0],[1787972280000,0],[1787972580000,0],[1787972880000,0],[1787973180000,0],[1787973480000,0],[1787973780000,0],[1787974080000,0],[1787974380000,0],[1787974680000,0],[1787974980000,0],[1787975280000,0],[1787975580000,0],[1787975880000,0],[1787976180000,0],[1787976480000,0],[1787976780000,0],[1787977080000,0],[1787977380000,0],[1787977680000,0],[1787977980000,0],], color: '#008fbf' } ]; var options = { xaxes: [{ axisLabel: 'rain', }], points: { show: false }, lines: { show: true, lineWidth: 2, fill: false, }, yaxis: { min: 0, }, xaxis: { mode: 'time', minTickSize: [1, 'hour'], timeformat: '%d.%m.\, %H:%M', timezone: 'browser', }, grid: { hoverable: true, clickable: true, borderWidth: 0, }, tooltip: { show: true, content: '%x - %y.3mm' }, crosshair: { mode: 'x' }, legend: { show: true, container: '#chart-rain-legend' } }; graphs['#chart-rain'] = $.plot('#chart-rain', dataset, options); }); $('.modal').on('hide.bs.modal', function() { var memory = $(this).html(); $(this).html(memory); }); function meteo_wind_direction_name(wind_direction) { if (wind_direction >= 0.00 && wind_direction <= 11.25) { ret = 'S'; } else if (wind_direction > 11.25 && wind_direction <= 33.75) { ret = 'SSV'; } else if (wind_direction > 33.75 && wind_direction <= 56.25) { ret = 'SV'; } else if (wind_direction > 56.25 && wind_direction <= 78.75) { // 67.5 ret = 'VSV'; } else if (wind_direction > 78.75 && wind_direction <= 101.25) { // 90 ret = 'V'; } else if (wind_direction > 101.25 && wind_direction <= 123.75) { //112.5 ret = 'VJV'; } else if (wind_direction > 123.75 && wind_direction <= 146.25) { // 135 ret = 'JV'; } else if (wind_direction > 146.25 && wind_direction <= 168.75) { // 157.5 ret = 'JJV'; } else if (wind_direction > 168.75 && wind_direction <= 191.25) { // 180 ret = 'J'; } else if (wind_direction > 191.25 && wind_direction <= 213.75) { // 202.5 ret = 'JJZ'; } else if (wind_direction > 213.75 && wind_direction <= 236.25) { // 225 ret = 'JZ'; } else if (wind_direction > 236.25 && wind_direction <= 258.75) { // 247.5 ret = 'ZJZ'; } else if (wind_direction > 258.75 && wind_direction <= 281.25) { // 270 ret = 'Z'; } else if (wind_direction > 281.25 && wind_direction <= 303.75) { // 292.5 ret = 'ZSZ'; } else if (wind_direction > 303.75 && wind_direction <= 326.25) { // 315 ret = 'SZ'; } else if (wind_direction > 326.25 && wind_direction <= 348.75) { // 337.5 ret = 'SSZ'; } else if (wind_direction > 348.75 && wind_direction <= 360.0) { // 337.5 ret = 'S'; } else { return ''; } return ret; }