Commit c1d69a6f authored by Carl Schreck's avatar Carl Schreck

Automated Nightly Commit - Wed Jul 31 00:01:27 EDT 2019

parent 9772ec81
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Carl Schreck (cjschrec@ncsu.edu)
; May 2019
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
; Description: Empty file to start NCL scripts
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
load "$CJS_NCL_LIB/lib.cjs_graphics.ncl"
load "$CJS_NCL_LIB/lib.array.ncl"
begin ; main
print_clock( "Here we go!" )
setfileoption("nc","Format","LargeFile")
; These are some parameters that could be useful to have up top
varName = "u200"
ioPath = "/home/carl/data/cfsr/sub120/" + varName + ".sub120.nc"
gridPath = "/home/carl/data/olr/current/olr.sub120.nc"
print_clock("Reading lat/lon")
gridFile = addfile(gridPath, "r")
grid_lat = gridFile->lat
grid_lon = gridFile->lon
print_clock("Reading " + varName)
inFile = addfile(ioPath, "r")
inData = inFile->$varName$
delete(inFile)
print_clock("Regridding")
outData = regrid_latlon(inData, grid_lat, grid_lon)
print_clock("Writing")
system("rm " + ioPath)
outFile = addfile(ioPath, "c")
outFile->$varName$ = outData
delete(outFile)
print_clock( "Thank you, come again." )
end; main
...@@ -26,15 +26,15 @@ begin ...@@ -26,15 +26,15 @@ begin
; These are some parameters that could be useful to have up top ; These are some parameters that could be useful to have up top
if( .not.isvar("varName") ) then if( .not.isvar("varName") ) then
varName = "u850" varName = "u200"
end if end if
standardizing = False standardizing = False
basePath = "~/data/era-interim/" basePath = "~/data/cfsr/"
; basePath = "~/data/olr/current/" ; basePath = "~/data/olr/current/"
; basePath = "/home/carl/data/nclimgrid/beta/merged/" ; basePath = "/home/carl/data/nclimgrid/beta/merged/"
if( True ) then if( True ) then
pathIn = basePath + "total/" + varName + ".nc" pathIn = basePath + "total/" + varName + ".total.nc"
pathClim = basePath + "clim/" + varName + ".clim.1988.2017.nc" pathClim = basePath + "clim/" + varName + ".clim.1988.2017.nc"
pathAnom = basePath + "anom/" + varName + ".anom.nc" pathAnom = basePath + "anom/" + varName + ".anom.nc"
pathStd = basePath + "std/" + varName + ".std.nc" pathStd = basePath + "std/" + varName + ".std.nc"
...@@ -46,8 +46,8 @@ begin ...@@ -46,8 +46,8 @@ begin
pathStd = basePath + varName + ".std.nc" pathStd = basePath + varName + ".std.nc"
end if end if
climStart = 1988001 climStart = 1981001
climEnd = 2017366 climEnd = 2010366
; Open the input files ; Open the input files
fin = addfile( pathIn, "r" ) fin = addfile( pathIn, "r" )
......
../cfsr/regrid_cfsr.ncl
\ No newline at end of file
...@@ -23,7 +23,7 @@ begin ...@@ -23,7 +23,7 @@ begin
; These are some parameters that could be useful to have up top ; These are some parameters that could be useful to have up top
obsPerDay = 1 obsPerDay = 1
dayAve = 60 dayAve = 120
nAve = dayAve * obsPerDay nAve = dayAve * obsPerDay
if( .not.isvar("varName") ) then if( .not.isvar("varName") ) then
...@@ -40,13 +40,13 @@ begin ...@@ -40,13 +40,13 @@ begin
else else
path = "/home/carl/data/cfsr/" path = "/home/carl/data/cfsr/"
inPath = path + "anom/" + varName + ".anom.nc" inPath = path + "anom/" + varName + ".anom.nc"
outPath = path + "waves/" + varName + "." + filtString + ".nc" outPath = path + filtString + "/" + varName + "." + filtString + ".nc"
end if end if
timeUnits = "days since 1800-01-01 00:00:00" timeUnits = "days since 1800-01-01 00:00:00"
minDateIn = cd_inv_calendar( 1979, 01, 01, 00, 0, 0, timeUnits, 0 ) minDateIn = cd_inv_calendar( 1979, 01, 01, 00, 0, 0, timeUnits, 0 )
maxDateIn = cd_inv_calendar( 2014, 12, 31, 18, 0, 0, timeUnits, 0 ) maxDateIn = cd_inv_calendar( 2018, 12, 31, 18, 0, 0, timeUnits, 0 )
setfileoption( "nc", "Format", "LargeFile" ) setfileoption( "nc", "Format", "LargeFile" )
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment