Ho provato a mettere a confronto le previsioni meteo dei servizi NOAA GFS ed Arpege visti nei precedenti post per una localita' italiana confrontando i dati con dati di verita' a terra dati da stazione meteo. Per rendere piu' agevole l'analisi il download ed il pretrattamento dei dati in CSV e' stato automatizzato
Script per NOAA GFS
-----------------------------------------------------------------------------------
rm $dove*.grib > /dev/null 2>&1
rm $dove*.csv > /dev/null 2>&1
rm /var/www/html/luca/gfs/completo.csv > /dev/null 2>&1
mv $dove*.txt ${dove}backup/ > /dev/null 2>&1
today=`date +%Y%m%d`
echo $today
# 11.8537, 46.4297
llon="11.75"
llat="46.25"
ulon="11.99"
ulat="46.49"
for i in $(seq -f "%03g" 0 120)
do
echo $i
wget -q -O ${dove}f${i}.grib "https://nomads.ncep.noaa.gov/cgi-bin/filter_gfs_0p25.pl?file=gfs.t00z.pgrb2.0p25.f$i&lev_2_m_above_ground=on&var_TMP=on&subregion=&leftlon=${llon}&rightlon=${ulon}&toplat=${ulat}&bottomlat=${llat}&dir=%2Fgfs.$today%2F00%2Fatmos"
done
for i in $(seq -f "%03g" 123 3 384) #123 126 129
do
echo $i
wget -q -O ${dove}f${i}.grib "https://nomads.ncep.noaa.gov/cgi-bin/filter_gfs_0p25.pl?file=gfs.t00z.pgrb2.0p25.f$i&lev_2_m_above_ground=on&var_TMP=on&subregion=&leftlon=${llon}&rightlon=${ulon}&toplat=${ulat}&bottomlat=${llat}&dir=%2Fgfs.$today%2F00%2Fatmos"
done
for i in $(seq -f "%03g" 0 120)
do
echo "Conversione grib${i}"
${dove}wgrib2 ${dove}f${i}.grib -csv ${dove}f${i}.csv
done
for i in $(seq -f "%03g" 123 3 384)
do
echo "Conversione grib${i}"
${dove}wgrib2 ${dove}f${i}.grib -csv ${dove}f${i}.csv
done
for i in $(seq -f "%03g" 0 120)
do
cat ${dove}f${i}.csv >> ${dove}${today}_completo.txt
done
for i in $(seq -f "%03g" 123 3 384)
do
cat ${dove}f${i}.csv >> ${dove}${today}_completo.txt
done
#aggiunge l'intestazione al csv
sed '1 s/^/data1,data2,variabile,unita,lon,lat,valore\n/' ${dove}${today}_completo.txt > ${dove}${today}_completo_1.txt
cp ${dove}${today}_completo_1.txt /var/www/html/luca/gfs/completo.csv