; =========================================== ; Archive maps from Alicia's Website ; Created by: Alicia M. Bentley ; Last updated: 2/28/2018 ; =========================================== load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/contrib/ut_string.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/contrib/calendar_decode2.ncl" ; =========================================== begin print(" ") print("**************") print(" START SCRIPT ") print("**************") ;----------------------------------------------- ; The only thing to change are in this section ;----------------------------------------------- start_img = 1 ; first image to archive end_img = 89 ; last image to archive dir_out = "/lb13/kbiernat/www/Dec_2018_to_Jan_2019_maps/images_v2/" ; change to the directory you want to put images in ; First list is all possible domain options ;folder = (/"NH","pacific","northamer","atlantic","europe","SH","southpac","southamer","india","australia"/) folder = (/"pacific","northamer","atlantic","conus"/) enddomain = dimsizes(folder) ; First list is all possible variable options variable = (/"6hprecip","mslp_jet","dt_2pvu","irro_wind","rel_vort","700wind_pw","IVT_conv","850_thetae","cape_shear","coupling","250wind_anom","250v_anom","500g_anom","pw_anom","850t_anom","925wind_anom","mslp_anom","350K_isen","330K_isen","310K_isen"/) ;variable = (/"IVT_conv","850_thetae","250wind_anom","500g_anom","irro_wind","mslp_jet"/) endvariable = dimsizes(variable) ;------------------------------------------------------------------------------------------------- ;------------------------------------------------------------------------------------------------- ;------------------------------------------------------------------------------------------------- system ("mkdir "+dir_out) ; create directory you want to put images in do x = 0,enddomain-1 domain = folder(x) do y = 0,endvariable-1 name = variable(y) system ("mkdir "+dir_out+domain+"/") system ("mkdir "+dir_out+domain+"/"+name+"/") do number = start_img,end_img,1 number_save = number+37 system ("'cp' /lb11/abentley/www/realtime/images/"+domain+"/"+name+"/"+name+"_"+number+".png "+dir_out+domain+"/"+name+"/"+name+"_"+number_save+".png") print("Archived "+domain+"/"+name+"_"+number+".png") end do ; end number end do ; end name end do ; end domain print(" ") print("**************") print(" END SCRIPT ") print("**************") print(" ") end