- Timestamp:
- 04/10/08 22:14:51 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/SRC/Interpolation/file_interp.pro
r330 r343 21 21 nan_value GT 1.e6:mask = temporary(mask) * (data LT (nan_value-10.)) 22 22 nan_value LT -1.e6:mask = temporary(mask) * (data GT (nan_value+10.)) 23 abs(nan_value) LT 1.e-6:mask = temporary(mask) * ( dataGT 1.e-6)23 abs(nan_value) LT 1.e-6:mask = temporary(mask) * (abs(data) GT 1.e-6) 24 24 ELSE:mask = temporary(mask) * (data NE nan_value) 25 25 ENDCASE … … 72 72 ; determined through <pro>ncdf_getmask</pro> according to the keywords 73 73 ; outmaskname, outinvmask, outuseasmask, outmissing_value, 74 ; outaddscl_before (see bellow) 74 ; outaddscl_before (see bellow). 75 75 ; 76 76 ; @keyword KEEP {type=string array}{default=all variables} … … 127 127 ; 128 128 ; @keyword INUSEASMASK {type=scalar string} 129 ; A string giving the name of the variable in the input mask file maskin130 ; that will be used to build the land/sea mask. In this case the129 ; A string giving the name of the variable in the input mask file 130 ; that will be used to build the input land/sea mask. In this case the 131 131 ; mask is based on the first record (if record dimension 132 ; exists). The mask is build according to : 133 ; 1 the keyword missing_value if existing 134 ; 2 the attribute 'missing_value' if existing 135 ; 3 NaN values if existing 132 ; exists). The input mask is build according to operator defined by INTESTOP 133 ; keyword (default NE) and the testing values defined as 134 ; 1) the second word of TESTOP if existing 135 ; 2) MISSING_VALUE keyword 136 ; 3) attribute missing_value or _fillvalue of the variable USEASMASK 137 ; 4) !Values.f_nan (can be used only with NE and EQ operators) 136 138 ; 137 139 ; @keyword OUTUSEASMASK {type=scalar string} … … 140 142 ; @keyword INMISSING_VALUE {type=scalar} 141 143 ; To define (or redefine if the attribute is already existing) the 142 ; missing values used by INUSEASMASK keyword 144 ; missing values used with INUSEASMASK keyword. Note that this value is 145 ; not used if INTESTOP keyword is given and contains 2 words. 143 146 ; 144 147 ; @keyword OUTMISSING_VALUE {type=scalar} 145 148 ; same as inmissing_value but for output mask file maskout 149 ; 150 ; @keyword INTESTOP {default='NE'} {type=scalar string, for example 'GT 0.5'} 151 ; a string describing the type of test that will be done to define the 152 ; input mask. The test is performed on the variable specified by INUSEASMASK 153 ; keyword. 154 ; INTESTOP can contain 1 or 2 words. The first word is the operator 155 ; definition: "EQ" "NE" "GE" "GT" "LE" "LT" (default is NE). The 156 ; second word define the testing value. If TESTOP contains only 1 157 ; word, then the test value is denifed by 158 ; 1) MISSING_VALUE keyword 159 ; 2) attribute missing_value or _fillvalue of the variable USEASMASK 160 ; 3) !Values.f_nan (can be used only with NE and EQ operators) 161 ; 162 ; @keyword OUTTESTOP {default='NE'} {type=scalar string, for example 'GT 0.5'} 163 ; same as INTESTOP but for output mask file maskout 146 164 ; 147 165 ; @keyword INADDSCL_BEFORE {default=0}{type=scalar: 0 or 1} … … 192 210 ; 193 211 ; - perform only horizontal interpolations on scalar fields 194 ; - will fill all masked and missing values before interpolation 212 ; - all masked and missing values are filled before interpolation 213 ; -> output data are not masked and have values everywhere. 195 214 ; - attributes (like valid_min...) are not updated 196 215 ; - see restrictions of <pro>fromreg</pro> and <pro>fromirr</pro> 216 ; - output mask is not used but, if the input file contains the mask 217 ; in a variable (defined by inmaskname), this variable will contain 218 ; the output mask in the ouput file 197 219 ; 198 220 ; @examples … … 214 236 , SET_XAXISNAME=set_xaxisname, SET_YAXISNAME=set_yaxisname $ 215 237 , INMASKNAME=inmaskname, ININVMASK=ininvmask $ 216 , INUSEASMASK=inuseasmask $ 217 , INMISSING_VALUE=inmissing_value $ 218 , INADDSCL_BEFORE=inaddscl_before $ 238 , INUSEASMASK=inuseasmask, INMISSING_VALUE=inmissing_value $ 239 , INADDSCL_BEFORE=inaddscl_before, INTESTOP = intestop $ 219 240 , OUTMASKNAME=outmaskname, OUTINVMASK=outinvmask $ 220 , OUTUSEASMASK=outuseasmask $ 221 , OUTMISSING_VALUE=outmissing_value $ 222 , OUTADDSCL_BEFORE=outaddscl_before $ 241 , OUTUSEASMASK=outuseasmask, OUTMISSING_VALUE=outmissing_value $ 242 , OUTADDSCL_BEFORE=outaddscl_before, OUTTESTOP = outtestop $ 223 243 , NAN_VALUE=NaN_value, WEIG=weig, ADDR=addr $ 224 244 , INXAXISNAME=inxaxisname, INYAXISNAME=inyaxisname $ … … 268 288 ; 269 289 inmask = ncdf_getmask(maskin, MASKNAME = inmaskname, INVMASK = ininvmask, USEASMASK = inuseasmask $ 270 , MISSING_VALUE = inmissing_value, ADDSCL_BEFORE = inaddscl_before )290 , MISSING_VALUE = inmissing_value, ADDSCL_BEFORE = inaddscl_before, TESTOP = intestop) 271 291 inmasksz = size(inmask, /dimensions) 272 292 IF size(inmask, /n_dimensions) EQ 2 THEN inmasksz = [inmasksz, 0] 273 293 IF n_elements(inmaskname) EQ 0 THEN inmaskname = 'not defined' ; default definition 274 294 outmask = ncdf_getmask(maskout, MASKNAME = outmaskname, INVMASK = outinvmask, USEASMASK = outuseasmask $ 275 , MISSING_VALUE = outmissing_value, ADDSCL_BEFORE = outaddscl_before )295 , MISSING_VALUE = outmissing_value, ADDSCL_BEFORE = outaddscl_before, TESTOP = outtestop) 276 296 ; 277 297 ; irregular grids?
Note: See TracChangeset
for help on using the changeset viewer.