#!/usr/bin/perl -w use POSIX; sub Usage{ print STDERR <> $file`; `psbasemap $location -Jm$jmscale $dscale $ticks -O -K >> $file`; # Coast Outline $misc = "-V -O -K"; # initial, allow overlay (-K) chomp($direct=`pwd`); print "$direct\n"; #`pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -S135/206/250 -W $misc >> $file`; `pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -W $misc >> $file`; ################################################# # Stations --- as triangles, and add station names print "stations now:\n"; $misc = "-Jm -R -V -O -K"; # for overlay and append #BB + SM PRSN JOINT STATIONS `awk '{print \$5,\$4}' ./prsmp_BBSM | psxy -G0/0/0 -Sd.4 -W1/0/0/0 $misc >> $file`; `awk '{print \$5-.02, \$4, 10, 0, 8, "BR", \$1}' ./prsmp_BBSM | pstext -G0 $misc >> $file`; #SM ETNA internet `awk '(\$1=="ETNAinternet"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/255/0 -Sc.3 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAinternet"){print \$4+.008, -1*\$5+.01, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/255/0 $misc >> $file`; #SM ETNA dialup `awk '(\$1=="ETNAdialup"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G255/0/0 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAdialup"){print \$4+.008, -1*\$5+.01, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G255/0/0 $misc >> $file`; #SM ETNA stand alone `awk '(\$1=="ETNAnocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/0/255 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAnocomm"){print \$4+.008, -1*\$5+.01, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/0/255 $misc >> $file`; #SM K2 stand alone `awk '(\$1=="K2nocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G100/100/100 -St.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="K2nocomm"){print \$4+.008, -1*\$5-.01, 10, 0, 8, "TR", \$2}' ./PRSMP_June05.txt | pstext -: -G50/50/50 $misc >> $file`; ##SM dialup only #`awk '{print \$1,-1*\$2}' ./All_PRSMP_SMstns.txt | psxy -G255/0/0 -Si.2 -: -W1/0/0/0 $misc >> $file`; #`awk '{print \$1+.008, -1*\$2+.01, 10, 0, 8, "TL", \$3}' ./All_PRSMP_SMstns.txt | pstext -: -G255/0/0 $misc >> $file`; #BB + SM #`awk '{print \$5,\$4}' ./prsmp_BBSM | psxy -G0/0/0 -Sd.3 -W1/0/0/0 $misc >> $file`; #`awk '{print \$5-.02, \$4, 10, 0, 8, "BR", \$1}' ./prsmp_BBSM | pstext -G0 $misc >> $file`; ##SM internet only #`awk '{print \$5,\$4}' ./prsmp_SMonly | psxy -G0/255/0 -Sc.2 -W1/0/0/0 $misc >> $file`; #`awk '{print \$5-.0, \$4-.02, 10, 0, 8, "BC", \$1}' ./prsmp_SMonly | pstext -G0/100/0 $misc >> $file`; ################################### #boxes / text $misc = "-Jm -R -V -O -K"; # for overlay and append $legA="EpiSensor 24bit realtime"; $legC="ETNA 18bit realtime"; $legD="ETNA 18bit dialup"; $legE="ETNA 18bit standalone"; $legF="K2 multichannel 19bit standalone"; #$legAA="currently out of operation ($wcBR stas)"; `pstext <> $file -67.3 17.8 12 1 4 LM $legA EOF`; `psxy <> $file -67.32 17.8 EOF`; `pstext <> $file -66.95 17.8 12 1 4 LM $legC EOF`; `psxy <> $file -66.97 17.8 EOF`; `pstext <> $file -66.65 17.8 12 1 4 LM $legD EOF`; `psxy <> $file -66.66 17.8 EOF`; `pstext <> $file -66.35 17.8 12 1 4 LM $legE EOF`; `psxy <> $file -66.36 17.8 EOF`; `pstext <> $file -65.99 17.8 12 1 4 LM $legF EOF`; `psxy <> $file -66.00 17.8 EOF`; ################################################# # Title $misc = "-Jm -R -V -O -K"; # for overlay only `pstext <> $file $titlelong $titlelat1 12 0 1 BC $title1 $titlelong $titlelat2 12 0 1 BC $title2 EOF`; ########################################### ###MAP 2 : Mayaguez only $latgrdmax=18.26; $latgrdmin=18.13; $longrdmax=-67.06; $longrdmin=-67.21; $titlelat1 = $latgrdmax + ($latgrdmax - $latgrdmin)*.06; $titlelat2 = $latgrdmax + ($latgrdmax - $latgrdmin)*.03; $titlelong = ($longrdmax + $longrdmin)/2; #start with some definitions for the plot $ticks = "-Ba3mf1m/a3mf1mSWne"; $resolution = "-Df"; $location = "-R${longrdmin}/${longrdmax}/${latgrdmin}/${latgrdmax}"; print "Map limits Location: $location\n"; $jmscale=45; $X=0; $Y=-9; $title1="Mayaguez area"; $title2=""; ################################################# # Coast Outline $misc = "-V -K -O"; # initial, allow overlay (-K) chomp($direct=`pwd`); print "$direct\n";$grd = "./JAY/9-sec.grd"; $cpt ="./JAY/pr-dr.cpt"; $dscale = "-Lf-67.18/18.15/8.50/3k"; `grdimage $grd -C$cpt $location -Jm$jmscale -K -V -O -X$X -Y$Y >> $file`; `psbasemap $location -Jm$jmscale $dscale $ticks -O -K >> $file`; # Coast Outline $misc = "-V -O -K"; # initial, allow overlay (-K) chomp($direct=`pwd`); print "$direct\n"; `pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -W2 $misc >> $file`; #`pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -S135/206/250 -W -X$X -Y$Y $misc >> $file`; $misc = "-Jm -R -V -O -K"; # for overlay and append #BB + SM PRSN JOINT STATIONS `awk '{print \$5,\$4}' ./prsmp_BBSM | psxy -G0/0/0 -Sd.4 -W1/0/0/0 $misc >> $file`; `awk '{print \$5-.002, \$4, 10, 0, 8, "BR", \$1}' ./prsmp_BBSM | pstext -G0 $misc >> $file`; #SM ETNA internet `awk '(\$1=="ETNAinternet"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/255/0 -Sc.3 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAinternet"){print \$4+.003, -1*\$5+.002, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/255/0 $misc >> $file`; #SM ETNA dialup `awk '(\$1=="ETNAdialup"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G255/0/0 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAdialup"){print \$4+.003, -1*\$5+.002, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G255/0/0 $misc >> $file`; #SM ETNA stand alone `awk '(\$1=="ETNAnocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/0/255 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAnocomm"){print \$4+.003, -1*\$5+.002, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/0/255 $misc >> $file`; #SM K2 stand alone `awk '(\$1=="K2nocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G10/10/10 -St.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="K2nocomm"){print \$4+.003, -1*\$5-.01, 10, 0, 8, "TR", \$2}' ./PRSMP_June05.txt | pstext -: -G50/50/50 $misc >> $file`; ################################################# # Title $misc = "-Jm -R -V -O -K"; # for overlay only `pstext <> $file $titlelong $titlelat1 12 0 1 BC $title1 $titlelong $titlelat2 12 0 1 BC $title2 EOF`; ########################################### ###MAP 3 : Ponce only $latgrdmax=18.05; $latgrdmin=17.95; $longrdmax=-66.55; $longrdmin=-66.65; $titlelat1 = $latgrdmax + ($latgrdmax - $latgrdmin)*.06; $titlelat2 = $latgrdmax + ($latgrdmax - $latgrdmin)*.03; $titlelong = ($longrdmax + $longrdmin)/2; #start with some definitions for the plot $ticks = "-Ba3mf1m/a3mf1mSWne"; $resolution = "-Df"; $location = "-R${longrdmin}/${longrdmax}/${latgrdmin}/${latgrdmax}"; print "Map limits Location: $location\n"; $jmscale=59; $X=8.8; $Y=0; $title1="Ponce area"; $title2=""; ################################################# # Coast Outline $misc = "-V -K -O"; # initial, allow overlay (-K) chomp($direct=`pwd`); print "$direct\n";$grd = "./JAY/9-sec.grd"; $cpt ="./JAY/pr-dr.cpt"; $dscale = "-Lf-66.63/18.03/8.50/3k"; `grdimage $grd -C$cpt $location -Jm$jmscale -K -V -O -X$X -Y$Y >> $file`; `psbasemap $location -Jm$jmscale $dscale $ticks -O -K >> $file`; # Coast Outline $misc = "-V -O -K"; `pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -W $misc >> $file`; #`pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -S135/206/250 -W -X$X -Y$Y $misc >> $file`; $misc = "-Jm -R -V -O -K"; # for overlay and append #BB + SM PRSN JOINT STATIONS `awk '{print \$5,\$4}' ./prsmp_BBSM | psxy -G0/0/0 -Sd.4 -W1/0/0/0 $misc >> $file`; `awk '{print \$5-.02, \$4, 10, 0, 8, "BR", \$1}' ./prsmp_BBSM | pstext -G0 $misc >> $file`; #SM ETNA internet `awk '(\$1=="ETNAinternet"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/255/0 -Sc.3 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAinternet"){print \$4+.003, -1*\$5+.002, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/255/0 $misc >> $file`; #SM ETNA dialup `awk '(\$1=="ETNAdialup"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G255/0/0 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAdialup"){print \$4+.003, -1*\$5+.002, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G255/0/0 $misc >> $file`; #SM ETNA stand alone `awk '(\$1=="ETNAnocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/0/255 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAnocomm"){print \$4+.003, -1*\$5+.002, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/0/255 $misc >> $file`; #SM K2 stand alone `awk '(\$1=="K2nocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G10/10/10 -St.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="K2nocomm"){print \$4+.003, -1*\$5+.03, 10, 0, 8, "TR", \$2}' ./PRSMP_June05.txt | pstext -: -G50/50/50 $misc >> $file`; ################################################# # Title $misc = "-Jm -R -V -O -K"; # for overlay only `pstext <> $file $titlelong $titlelat1 12 0 1 BC $title1 $titlelong $titlelat2 12 0 1 BC $title2 EOF`; ########################################### ###MAP 4 : Metropolitan Area only $latgrdmax=18.5; $latgrdmin=18.3; $longrdmax=-65.9; $longrdmin=-66.18; $titlelat1 = $latgrdmax + ($latgrdmax - $latgrdmin)*.06; $titlelat2 = $latgrdmax + ($latgrdmax - $latgrdmin)*.03; $titlelong = ($longrdmax + $longrdmin)/2; #start with some definitions for the plot $ticks = "-Ba3mf1m/a3mf1mSWne"; $resolution = "-Df"; $location = "-R${longrdmin}/${longrdmax}/${latgrdmin}/${latgrdmax}"; print "Map limits Location: $location\n"; $jmscale=30; $X=8; $Y=0; $title1="Metropolitan Area"; $title2=""; ################################################# # Coast Outline $misc = "-V -K -O"; # initial, allow overlay (-K) chomp($direct=`pwd`); print "$direct\n"; $grd = "./JAY/9-sec.grd"; $cpt ="./JAY/pr-dr.cpt"; $dscale = "-Lf-65.95/18.34/8.50/6k"; `grdimage $grd -C$cpt $location -Jm$jmscale -K -V -O -X$X -Y$Y >> $file`; `psbasemap $location -Jm$jmscale $dscale $ticks -O -K >> $file`; # Coast Outline $misc = "-V -O -K"; # initial, allow overlay (-K) chomp($direct=`pwd`); print "$direct\n"; `pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -W $misc >> $file`; #`pscoast -Jm$jmscale $location $ticks $resolution -Ii/1/0/0/150 -Na -S135/206/250 -W -X$X -Y$Y $misc >> $file`; $misc = "-Jm -R -V -O -K"; # for overlay and append #BB + SM PRSN JOINT STATIONS `awk '{print \$5,\$4}' ./prsmp_BBSM | psxy -G0/0/0 -Sd.4 -W1/0/0/0 $misc >> $file`; `awk '{print \$5-.02, \$4, 10, 0, 8, "BR", \$1}' ./prsmp_BBSM | pstext -G0 $misc >> $file`; #SM ETNA internet `awk '(\$1=="ETNAinternet"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/255/0 -Sc.3 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAinternet"){print \$4+.003, -1*\$5+.005, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/255/0 $misc >> $file`; #SM ETNA dialup `awk '(\$1=="ETNAdialup"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G255/0/0 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAdialup"){print \$4+.003, -1*\$5+.005, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G255/0/0 $misc >> $file`; #SM ETNA stand alone `awk '(\$1=="ETNAnocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G0/0/255 -Si.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="ETNAnocomm"){print \$4+.003, -1*\$5+.005, 10, 0, 8, "TL", \$2}' ./PRSMP_June05.txt | pstext -: -G0/0/255 $misc >> $file`; #SM K2 stand alone `awk '(\$1=="K2nocomm"){print \$4,-1*\$5}' ./PRSMP_June05.txt | psxy -G100/100/100 -St.2 -: -W1/0/0/0 $misc >> $file`; `awk '(\$1=="K2nocomm"){print \$4+.003, -1*\$5-.005, 10, 0, 8, "TR", \$2}' ./PRSMP_June05.txt | pstext -: -G50/50/50 $misc >> $file`; ################################################# # Title $misc = "-Jm -R -V -O"; # for overlay only `pstext <> $file $titlelong $titlelat1 12 0 1 BC $title1 $titlelong $titlelat2 12 0 1 BC $title2 EOF`;