var graphs = {}; $(document).ready(function() { dataset = [ { label: 'Teplota (°C)', data: [[1787954400000,13.50000000],[1787954580000,13.42000000],[1787954880000,13.38000000],[1787955180000,13.40000000],[1787955480000,13.40000000],[1787955780000,13.42000000],[1787956080000,13.40000000],[1787956380000,13.30000000],[1787956680000,13.34000000],[1787956980000,13.32000000],[1787957280000,13.30000000],[1787957580000,13.30000000],[1787957880000,13.28000000],[1787958180000,13.28000000],[1787958480000,13.20000000],[1787958780000,13.20000000],[1787959080000,13.20000000],[1787959380000,13.24000000],[1787959680000,13.30000000],[1787959980000,13.38000000],[1787960280000,13.52000000],[1787960580000,13.64000000],[1787960880000,13.82000000],[1787961180000,13.96000000],[1787961480000,14.00000000],[1787961780000,13.96000000],[1787962080000,13.80000000],[1787962380000,13.74000000],[1787962680000,13.76000000],[1787962980000,13.82000000],[1787963280000,14.02000000],[1787963580000,14.00000000],[1787963880000,14.16000000],[1787964180000,14.36000000],[1787964480000,14.48000000],[1787964780000,14.58000000],[1787965080000,14.68000000],[1787965380000,14.76000000],[1787965680000,14.80000000],[1787965980000,15.08000000],[1787966280000,15.22000000],[1787966580000,15.24000000],[1787966880000,15.14000000],[1787967180000,15.10000000],[1787967480000,15.20000000],[1787967780000,15.24000000],[1787968080000,15.20000000],[1787968380000,15.12000000],[1787968680000,15.04000000],[1787968980000,15.00000000],[1787969280000,15.00000000],[1787969580000,15.00000000],[1787969880000,15.00000000],[1787970180000,15.00000000],[1787970480000,14.86000000],[1787970780000,14.68000000],[1787971080000,14.56000000],[1787971380000,14.34000000],[1787971680000,14.20000000],[1787971980000,14.06000000],[1787972280000,13.94000000],[1787972580000,13.84000000],[1787972880000,13.80000000],[1787973180000,13.70000000],[1787973480000,13.78000000],[1787973780000,13.88000000],[1787974080000,13.86000000],[1787974380000,13.92000000],[1787974680000,14.08000000],[1787974980000,14.18000000],[1787975280000,14.20000000],[1787975580000,14.28000000],[1787975880000,14.34000000],[1787976180000,14.40000000],[1787976480000,14.48000000],[1787976780000,14.50000000],[1787977080000,14.60000000],[1787977380000,14.62000000],[1787977680000,14.70000000],[1787977980000,14.80000000],], color: '#d6212a' }, { label: 'Rosný bod (°C)', data: [[1787954400000,8.3],[1787954580000,8.1],[1787954880000,8],[1787955180000,8.1],[1787955480000,7.8],[1787955780000,8.1],[1787956080000,8],[1787956380000,8.2],[1787956680000,7.9],[1787956980000,8.2],[1787957280000,8],[1787957580000,8.1],[1787957880000,8],[1787958180000,8.1],[1787958480000,8],[1787958780000,7.9],[1787959080000,8.1],[1787959380000,8],[1787959680000,8.2],[1787959980000,8.2],[1787960280000,8.4],[1787960580000,8.4],[1787960880000,8.3],[1787961180000,8.3],[1787961480000,8.4],[1787961780000,8.5],[1787962080000,8.5],[1787962380000,8.3],[1787962680000,8.4],[1787962980000,8],[1787963280000,8.6],[1787963580000,8.7],[1787963880000,8.1],[1787964180000,8.9],[1787964480000,8.6],[1787964780000,8.8],[1787965080000,9],[1787965380000,8.9],[1787965680000,9.2],[1787965980000,8.6],[1787966280000,8.8],[1787966580000,9],[1787966880000,9.3],[1787967180000,9.1],[1787967480000,8.8],[1787967780000,9.4],[1787968080000,9.5],[1787968380000,9.7],[1787968680000,9.5],[1787968980000,9.4],[1787969280000,9.2],[1787969580000,9.4],[1787969880000,9.4],[1787970180000,9.8],[1787970480000,9.8],[1787970780000,9.3],[1787971080000,9.5],[1787971380000,9.4],[1787971680000,9.2],[1787971980000,9.2],[1787972280000,9.2],[1787972580000,9.1],[1787972880000,9.1],[1787973180000,9],[1787973480000,8.9],[1787973780000,8.9],[1787974080000,9.2],[1787974380000,9.1],[1787974680000,9.2],[1787974980000,9.5],[1787975280000,9.5],[1787975580000,9.6],[1787975880000,9.7],[1787976180000,9.8],[1787976480000,9.9],[1787976780000,9.8],[1787977080000,9.9],[1787977380000,10],[1787977680000,10.1],[1787977980000,10],], 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.80000000],[1787954580000,11.78000000],[1787954880000,11.72000000],[1787955180000,11.66000000],[1787955480000,11.78000000],[1787955780000,11.78000000],[1787956080000,11.78000000],[1787956380000,11.68000000],[1787956680000,11.72000000],[1787956980000,11.72000000],[1787957280000,11.66000000],[1787957580000,11.62000000],[1787957880000,11.68000000],[1787958180000,11.64000000],[1787958480000,11.54000000],[1787958780000,11.64000000],[1787959080000,11.68000000],[1787959380000,12.00000000],[1787959680000,12.58000000],[1787959980000,12.96000000],[1787960280000,13.32000000],[1787960580000,13.60000000],[1787960880000,13.74000000],[1787961180000,13.66000000],[1787961480000,13.12000000],[1787961780000,12.70000000],[1787962080000,12.28000000],[1787962380000,12.08000000],[1787962680000,12.18000000],[1787962980000,12.72000000],[1787963280000,13.32000000],[1787963580000,13.64000000],[1787963880000,14.08000000],[1787964180000,14.24000000],[1787964480000,14.40000000],[1787964780000,14.50000000],[1787965080000,14.66000000],[1787965380000,14.72000000],[1787965680000,14.80000000],[1787965980000,15.02000000],[1787966280000,14.96000000],[1787966580000,14.52000000],[1787966880000,14.40000000],[1787967180000,14.64000000],[1787967480000,14.98000000],[1787967780000,15.00000000],[1787968080000,14.90000000],[1787968380000,14.66000000],[1787968680000,14.40000000],[1787968980000,14.58000000],[1787969280000,14.78000000],[1787969580000,14.78000000],[1787969880000,14.64000000],[1787970180000,14.50000000],[1787970480000,13.88000000],[1787970780000,13.34000000],[1787971080000,13.02000000],[1787971380000,12.82000000],[1787971680000,12.54000000],[1787971980000,12.50000000],[1787972280000,12.36000000],[1787972580000,12.22000000],[1787972880000,12.30000000],[1787973180000,12.26000000],[1787973480000,12.36000000],[1787973780000,12.78000000],[1787974080000,13.24000000],[1787974380000,13.68000000],[1787974680000,13.96000000],[1787974980000,14.08000000],[1787975280000,14.12000000],[1787975580000,14.28000000],[1787975880000,14.40000000],[1787976180000,14.50000000],[1787976480000,14.64000000],[1787976780000,14.60000000],[1787977080000,14.76000000],[1787977380000,14.86000000],[1787977680000,14.98000000],[1787977980000,15.07500000],], 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,70.80000000],[1787954580000,70.46000000],[1787954880000,70.32000000],[1787955180000,70.52000000],[1787955480000,69.28000000],[1787955780000,70.66000000],[1787956080000,70.28000000],[1787956380000,71.34000000],[1787956680000,69.88000000],[1787956980000,71.20000000],[1787957280000,70.32000000],[1787957580000,70.78000000],[1787957880000,70.38000000],[1787958180000,71.14000000],[1787958480000,70.78000000],[1787958780000,70.68000000],[1787959080000,71.64000000],[1787959380000,70.70000000],[1787959680000,71.56000000],[1787959980000,70.86000000],[1787960280000,71.56000000],[1787960580000,70.66000000],[1787960880000,69.50000000],[1787961180000,68.74000000],[1787961480000,69.14000000],[1787961780000,70.10000000],[1787962080000,70.44000000],[1787962380000,69.80000000],[1787962680000,70.50000000],[1787962980000,68.04000000],[1787963280000,69.90000000],[1787963580000,70.70000000],[1787963880000,67.12000000],[1787964180000,70.08000000],[1787964480000,68.10000000],[1787964780000,68.52000000],[1787965080000,69.10000000],[1787965380000,68.14000000],[1787965680000,69.46000000],[1787965980000,65.56000000],[1787966280000,65.72000000],[1787966580000,66.56000000],[1787966880000,68.36000000],[1787967180000,67.42000000],[1787967480000,65.80000000],[1787967780000,68.30000000],[1787968080000,69.02000000],[1787968380000,70.38000000],[1787968680000,69.50000000],[1787968980000,69.40000000],[1787969280000,68.56000000],[1787969580000,69.52000000],[1787969880000,69.40000000],[1787970180000,71.22000000],[1787970480000,71.90000000],[1787970780000,70.36000000],[1787971080000,71.78000000],[1787971380000,72.34000000],[1787971680000,72.16000000],[1787971980000,72.76000000],[1787972280000,73.24000000],[1787972580000,73.46000000],[1787972880000,73.64000000],[1787973180000,73.28000000],[1787973480000,72.60000000],[1787973780000,72.06000000],[1787974080000,73.76000000],[1787974380000,72.74000000],[1787974680000,72.86000000],[1787974980000,73.54000000],[1787975280000,73.72000000],[1787975580000,73.54000000],[1787975880000,73.68000000],[1787976180000,73.84000000],[1787976480000,74.00000000],[1787976780000,73.38000000],[1787977080000,73.84000000],[1787977380000,73.82000000],[1787977680000,74.20000000],[1787977980000,73.35000000],], 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.400000012],[1787954580000,2.952],[1787954880000,1.224],[1787955180000,2.952],[1787955480000,1.8],[1787955780000,1.656],[1787956080000,1.944],[1787956380000,2.304],[1787956680000,1.8],[1787956980000,3.384],[1787957280000,1.872],[1787957580000,1.944],[1787957880000,1.512],[1787958180000,1.8],[1787958480000,1.44],[1787958780000,2.16],[1787959080000,2.16],[1787959380000,1.368],[1787959680000,3.312],[1787959980000,1.872],[1787960280000,2.16],[1787960580000,1.368],[1787960880000,1.728],[1787961180000,0.648],[1787961480000,1.296],[1787961780000,2.376],[1787962080000,1.512],[1787962380000,2.232],[1787962680000,2.88],[1787962980000,3.096],[1787963280000,2.88],[1787963580000,1.944],[1787963880000,2.592],[1787964180000,3.168],[1787964480000,1.656],[1787964780000,2.448],[1787965080000,1.512],[1787965380000,1.872],[1787965680000,2.736],[1787965980000,2.304],[1787966280000,2.088],[1787966580000,1.296],[1787966880000,2.52],[1787967180000,0.936],[1787967480000,2.52],[1787967780000,1.44],[1787968080000,1.008],[1787968380000,2.304],[1787968680000,1.152],[1787968980000,1.368],[1787969280000,1.512],[1787969580000,1.224],[1787969880000,1.872],[1787970180000,1.944],[1787970480000,1.872],[1787970780000,1.584],[1787971080000,1.584],[1787971380000,1.584],[1787971680000,0.648],[1787971980000,1.872],[1787972280000,3.096],[1787972580000,3.024],[1787972880000,1.728],[1787973180000,1.368],[1787973480000,3.096],[1787973780000,2.736],[1787974080000,2.232],[1787974380000,1.368],[1787974680000,0.792],[1787974980000,1.368],[1787975280000,1.44],[1787975580000,2.16],[1787975880000,0.648],[1787976180000,1.152],[1787976480000,1.368],[1787976780000,1.944],[1787977080000,1.368],[1787977380000,1.512],[1787977680000,2.736],[1787977980000,2.61],], color: '#002f80', points: { show: false }, lines: { show: true, lineWidth: 2, fill: false, }, }, { label: 'Náraz vetra (km/h)', data: [[1787954400000,3.719999988],[1787954580000,3.816],[1787954880000,1.944],[1787955180000,3.816],[1787955480000,2.952],[1787955780000,2.448],[1787956080000,2.736],[1787956380000,3.168],[1787956680000,2.52],[1787956980000,4.32],[1787957280000,2.52],[1787957580000,2.664],[1787957880000,2.304],[1787958180000,2.808],[1787958480000,2.448],[1787958780000,3.024],[1787959080000,2.808],[1787959380000,2.16],[1787959680000,4.104],[1787959980000,2.664],[1787960280000,3.024],[1787960580000,1.728],[1787960880000,2.304],[1787961180000,1.08],[1787961480000,2.232],[1787961780000,3.168],[1787962080000,2.232],[1787962380000,3.312],[1787962680000,4.032],[1787962980000,4.392],[1787963280000,3.888],[1787963580000,2.736],[1787963880000,3.672],[1787964180000,4.608],[1787964480000,2.448],[1787964780000,3.096],[1787965080000,2.088],[1787965380000,2.664],[1787965680000,3.528],[1787965980000,3.888],[1787966280000,2.808],[1787966580000,1.728],[1787966880000,3.168],[1787967180000,1.44],[1787967480000,3.456],[1787967780000,2.16],[1787968080000,1.656],[1787968380000,2.664],[1787968680000,1.512],[1787968980000,1.872],[1787969280000,2.376],[1787969580000,1.728],[1787969880000,2.664],[1787970180000,2.736],[1787970480000,2.808],[1787970780000,2.16],[1787971080000,2.664],[1787971380000,2.52],[1787971680000,1.08],[1787971980000,2.52],[1787972280000,3.744],[1787972580000,4.104],[1787972880000,2.376],[1787973180000,2.52],[1787973480000,4.176],[1787973780000,3.96],[1787974080000,3.168],[1787974380000,2.088],[1787974680000,1.368],[1787974980000,1.944],[1787975280000,1.872],[1787975580000,2.88],[1787975880000,1.08],[1787976180000,1.584],[1787976480000,1.8],[1787976780000,2.736],[1787977080000,1.944],[1787977380000,1.944],[1787977680000,4.248],[1787977980000,3.6],], 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,275.00000000],[1787954580000,133.34000000],[1787954880000,235.02000000],[1787955180000,255.98000000],[1787955480000,256.36000000],[1787955780000,240.30000000],[1787956080000,247.78000000],[1787956380000,273.72000000],[1787956680000,222.00000000],[1787956980000,263.16000000],[1787957280000,235.16000000],[1787957580000,228.98000000],[1787957880000,197.16000000],[1787958180000,241.10000000],[1787958480000,142.32000000],[1787958780000,232.22000000],[1787959080000,264.88000000],[1787959380000,226.18000000],[1787959680000,261.56000000],[1787959980000,160.10000000],[1787960280000,257.40000000],[1787960580000,266.68000000],[1787960880000,188.96000000],[1787961180000,266.24000000],[1787961480000,264.84000000],[1787961780000,271.86000000],[1787962080000,143.08000000],[1787962380000,181.06000000],[1787962680000,240.32000000],[1787962980000,173.60000000],[1787963280000,247.78000000],[1787963580000,220.36000000],[1787963880000,207.62000000],[1787964180000,276.98000000],[1787964480000,110.20000000],[1787964780000,227.78000000],[1787965080000,145.92000000],[1787965380000,213.48000000],[1787965680000,193.98000000],[1787965980000,194.68000000],[1787966280000,208.08000000],[1787966580000,186.94000000],[1787966880000,244.38000000],[1787967180000,119.26000000],[1787967480000,186.46000000],[1787967780000,200.94000000],[1787968080000,252.16000000],[1787968380000,237.04000000],[1787968680000,53.36000000],[1787968980000,277.84000000],[1787969280000,186.78000000],[1787969580000,50.44000000],[1787969880000,215.06000000],[1787970180000,269.04000000],[1787970480000,105.10000000],[1787970780000,199.16000000],[1787971080000,198.02000000],[1787971380000,184.80000000],[1787971680000,187.48000000],[1787971980000,231.82000000],[1787972280000,267.60000000],[1787972580000,264.92000000],[1787972880000,89.04000000],[1787973180000,122.48000000],[1787973480000,220.14000000],[1787973780000,212.44000000],[1787974080000,259.34000000],[1787974380000,129.82000000],[1787974680000,132.80000000],[1787974980000,141.14000000],[1787975280000,159.70000000],[1787975580000,204.40000000],[1787975880000,230.38000000],[1787976180000,169.46000000],[1787976480000,113.00000000],[1787976780000,103.28000000],[1787977080000,165.20000000],[1787977380000,243.80000000],[1787977680000,176.88000000],[1787977980000,212.40000000],], 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; }