#This directory contains the monthly averaged time series and their anomaly time series for #TMT (MSU channel 2 and AMSU-A channel 5), TTS (MSU channel 3 and AMSU-A channel 7), and TLS #(MSU channel 4 and AMSU-A channel 9) derived from NOAA TIROS-N through NOAA-18 and MetOp-A and #NASA EOS Aqua. The grid resolution for these datasets is 2.5 degree latitude x 2.5 degree longitud #1) Merged_Deep-Layer_Temperature: Merged monthly deep-layer temperature time series for TMT, TTS, and TLS. # Christy bias correction was applied to further remove intersatellite biases after the SNO calibration. # TMT and TLS: November 1978 - present. # TTS: January 1981 - present. #2) Anomaly_Time_Series: Monthly anomaly time series for TMT, TTS, and TLS. # The temperature anomaly for each layer was generated using mean annual cycle for the period of 2000-2010. #Merged Deep Layer #3 dsets of ~13 MB #2x3 dsets of 49 MB #GLObal mean Anom # 3 dsets of 49 KB ##DEC 2016 #versions 3.0 and 4.0 #ftp://ftp.star.nesdis.noaa.gov/pub/smcd/emb/mscat/data/MSU_AMSU_v3.0/ #Merged Deep Layer/ #ftp://ftp.star.nesdis.noaa.gov/pub/smcd/emb/mscat/data/MSU_AMSU_v4.0/ #ftp://ftp.star.nesdis.noaa.gov/pub/smcd/emb/mscat/data/MSU_AMSU_v3.0/Monthly_Atmospheric_Layer_Mean_Temperature/ #two subdirectories: #Global_Mean_Anomaly_Time_Series/ #Merged_Deep-Layer_Temperature/ #Merged_Deep-Layer are 45MB TLS, TMT, TUT #function retrieves AMSU5 from Monthly_Atmospheric_layer #GLB MSU2,3, 4 get_noaa= function(tropo="TMT",zone="glb",mm="201611") { require(ncdf4) alias=c(TLT="MSU2",TMT="MSU3") D=format(Sys.Date(),"%Y") if(zone=="glb") { # zone="glb"; tropo="TMT" prefix="ftp://ftp.star.nesdis.noaa.gov/pub/smcd/emb/mscat/data/MSU_AMSU_v3.0/Monthly_Atmospheric_Layer_Mean_Temperature" directory="Global_Mean_Anomaly_Time_Series" fred=download_html(file.path(prefix,directory)) y=fred[grep(alias[paste(tropo)],fred)] z=strsplit(y,">")[[1]][2] n=nchar(z) suffix=substr(z,1,n-3) loc=file.path(prefix,directory,suffix) download.file(loc,dest) #readLines(dest,n=10) work=read.table(dest,header=T) names(work) #[1] "Year" "Month" "Ftime" "Global_Mean_Anomaly" "NH_Anomaly" #[6] "SH_Anomaly" "Global_Land_Anomaly" "Global_Ocean_Anomaly" names(work)=c("yy","month","year","glb","nh","sh","land","ocean") work=ts(work,start=c(1978,11),freq=12) return(work) } if(zone=="trp") { #this works for TMT; retrieving nc version #there are dat versions for MSU2, MSU3, ## loc="ftp://ftp.star.nesdis.noaa.gov/pub/smcd/emb/mscat/data/MSU_AMSU_v3.0/Monthly_Atmospheric_Layer_Mean_Temperature/ # tropo="TMT";zone="trp" prefix="ftp://ftp.star.nesdis.noaa.gov/pub/smcd/emb/mscat/data/MSU_AMSU_v3.0/Monthly_Atmospheric_Layer_Mean_Temperature" directory="Merged_Deep-Layer_Temperature" fred=download_html(file.path(prefix,directory)) y=fred[grep(tropo,fred)] y=y[grep("nc",y)] z=strsplit(y,">")[[1]] n=nchar(z[2]) suffix=substr(z[2],1,n-3) download.file(file.path(prefix,directory,suffix),dest,mode="wb") v=nc_open(dest) work=ncvar_get(v) dim(work) #[1] 144 72 449 #v$dim$lat$vals # S to N #v$dim$lon$vals # -180- 180 temp= abs(v$dim$lat$vals)<=20;sum(temp) #16 nc_close(v) out=apply(work[,temp,],3,mean) out=ts(out,start=c(1978,11),freq=12) #absolute temperature return(out) } #trp } #noaa_trp=out