      SUBROUTINE OPTION(ID,FD,FD1,FD2,FD3,FD4,JJ,II,TEMP,NDIR,NX,IPOS,
     *                  NST,XX,ITYPE,ICND,FD5,FD6,FD7,FD8)
C$$$  SUBPROGRAM DOCUMENTATION BLOCK                                    
C                                                                       
C SUBPROGRAM:    OPTION      CALLS MDL COMPUTED PREDICTOR SUBROUTINES   
C   PRGMMR: DALLAVALLE         ORG:W/OSD211        DATE: 88-02-08       
C                                                                       
C ABSTRACT: THIS SUBROUTINE ACTS AS A DRIVING PROGRAM TO CALL THE       
C   MDL PREDICTOR COMPUTATION SUBROUTINES                               
C                                                                       
C PROGRAM HISTORY LOG:                                                  
C   77-05-01  GLAHN, BETHEM                                             
C   85-02-01  JENSENIUS,DALLAVALLE  MADE GENERAL IMPROVEMENTS TO THE    
C                                   LOGIC, AS WELL AS ADDING DIFAVG     
C   88-02-08  DALLAVALLE   ADDS CALL TO COMPUTE THE DEW POINT DEPRESSION
C                          AT 300MB                                     
C   91-06-01  GILBERT   CONVERTED TO FORTRAN 77 AND ADDED FOUR MORE     
C                       FD ARRAYS AS WORK SPACE                         
C   91-09-01  DALLAVALLE   ADDED CALLS TO MANY NEW PREDICTOR SUBROUTINES
C   92-08-03  GILBERT      ADDED CALLS TO MONFQ2 AND FORIE2 TO MATCH    
C                          SETTELMAIER'S CHANGE TO M201'S OPTION        
C   92-10-18  DALLAVALLE   ADDED CALLS TO HGTDD, ZRPRED AND LOGIT       
C                          PREDICTOR SUBROUTINES                        
C   93-05-03  GILBERT      ADDED CALL TO MOSPRD FOR NGM SNOW AMT.       
C   93-06-04  DALLAVALLE   ADDED CALL TO OBSPRD FOR NGM VIS/OBVIS.      
C   93-09-15  DALLAVALLE   ADDED ANOTHER CALL TO OBSPRD FOR NGM         
C                          OBVIS PREDICTOR; CHANGED ALLOWABLE           
C                          PREDICTOR IDS FOR CALL TO VVBIN              
C   93-12-10  ERICKSON     CHANGED ID TEST TO CALL OBSPRD               
C                          ADDED OBS PREDICTOR IDS 116, 117,            
C                          118, AND 119 FOR TEMP/DEWPT AVG,             
C                          ZP/NO ZP, SNOW/NO SNOW, RAIN/NO RAIN         
C   93-12-15  DALLAVALLE   ADDED CALL TO WNDBIN (WIND BINARY)           
C                          FOR SHORT/MEDIUM RANGE TEMPERATURES          
C   94-02-21  DALLAVALLE   ADDED CALL TO HTZBIN (FREEZING LEVEL         
C                          GRID BINARY), MODIFIED TESTS (NEW ID'S)      
C                          FOR RHMEAN, MODIFIED TESTS (NEW ID'S)        
C                          FOR THKBIN, ADDED CALL TO VDELZ (TERRAIN     
C                          INDUCED VERT. VEL.), MODIFIED IF TEST (NEW   
C                          ID'S) FOR RHSIVV, AND ADDED CALL TO          
C                          PCPINT (NEW PREDICTOR SUBROUTINE FOR         
C                          AN INTERACTIVE VARIABLE BETWEEN THE          
C                          GRID-BINARY PRECIP. AMT (.01 INCHES) AND     
C                          EITHER THE VERTICAL VELOCITY OR THE GRID     
C                          BINARY OF THE FREEZING LEVEL HEIGHT (925 MB) 
C                          THESE CHANGES WERE MADE TO IMPLEMENT THE     
C                          ALASKA SNOW AMOUNT FORECAST EQUATIONS        
C                          DEVELOPED BY BRENT BOWER.                    
C   94-05-20  DALLAVALLE   ADDED CALL TO CADPRD (2 M TEMPERATURE        
C                          PREDICTOR INTERPOLATED FROM NGM ISOBARIC     
C                          TEMPERATURES).  THIS CHANGE WAS MADE IN      
C                          ANTICIPATION OF THE IMPLEMENTATION OF        
C                          3-MONTH NGM-BASED MX/MN/3-H TMP/3-H DP       
C                          EQUATIONS DEVELOPED BY WEI YAN.              
C   95-06-19  MEYER        CHANGED ID TEST TO CALL OBSPRD.  ADDED       
C                          OBS PREDICTOR IDS 128, 129, 130, AND 131     
C                          FOR BLOWING/NO BLOWING, FOG/NO FOG, HAZE/    
C                          NO HAZE, AND PRECIP/NO PRECIP.  THIS CHANGE  
C                          WAS MADE DO TO THE IMPLEMENTATION OF CIG AND 
C                          VIS/OBVIS EQUATIONS FOR ALASKA DEVELOPED BY  
C                          FRED MEYER.                                  
C   95-08-01  DALLAVALLE   MODIFIED IF TESTS FOR SEASONAL/MONTHLY       
C                          RELATIVE FREQUENCIES TO ACCOUNT FOR NEW      
C                          SEASONAL RELATIVE FREQUENCIES USED BY        
C                          WEI YAN AND MARK ANTOLIK IN DEVELOPMENT OF   
C                          NGM-BASED POPC AND QPF, RESPECTIVELY.        
C                          RELATIVE FREQUENCIES ADDED TO CONSTANT FILE  
C                          IN DECEMBER 1994.                            
C   98-08-28  ERICKSON/
C             SHIREY       ADDED DIMENSIONS FOR FD ARRAYS, TEMP AND 
C                          NDIR.  DEFINED VARIABLE IBJ.  
C                                                                       
C USAGE:                                                                
C                                                                       
C   SEE BELOW FOR MDL STANDARDS                                         
C                                                                       
C     PROGRAM OPTION                                                    
C                                                                       
C     PURPOSE                                                           
C        TO SERVE AS CALLING PROGRAM FOR COMPUTATION SUBROUTINES.       
C                                                                       
C     VARIABLES                                                         
C           ID( ) = 2-WORD MDL ID.                                      
C       FD(JJ,II) = PREDICTOR RETURNED HERE IF ITYPE = 0.               
C      FD1(JJ,II) = WORK ARRAY.                                         
C      FD2(JJ,II) = WORK ARRAY.                                         
C      FD3(JJ,II) = WORK ARRAY.                                         
C      FD4(JJ,II) = WORK ARRAY.                                         
C      FD5(JJ,II) = WORK ARRAY.                                         
C      FD6(JJ,II) = WORK ARRAY.                                         
C      FD7(JJ,II) = WORK ARRAY.                                         
C      FD8(JJ,II) = WORK ARRAY.                                         
C        TEMP(NX) = PREDICTOR RETURNED HERE IF ITYPE = 1.               
C      NDIR(NX, ) = X,Y-POSITIONS OF STATIONS.                          
C             NST = NUMBER OF STATIONS.                                 
C            IPOS = COLUMN IN NDIR( , ) THAT CONTAINS X-POSITIONS.      
C           MODP1 = MODEL NUMBER PLUS 1.                                
C          NCYCLE = CYCLE, 00 OR 12.                                    
C           ITYPE = 0 IF PREDICTOR IS A GRID FIELD,                     
C                   1 IF PREDICTOR IS AT STATIONS.                      
C            ICND = 0 IF GOOD RETURN.                                   
C            IDIF = HIGH ORDER MODIFICATION DIGIT. THE                  
C                   ALGORITHM TO HANDLE THIS SPECIFICATION              
C                   OF TIME DIFFERENCING(1-4) OR AVERAGING(5-7)         
C                   IS ACTUALLY LOCATED IN PRED AND DIFAVG.  IDIF       
C                   IS USED IN OPTION ONLY TO COMPUTE 24-H PRECIP AMT.  
C                                                                       
C        COMMON BLOCKS                                                  
C              M90201 -                                                 
C                                                                       
C        SUBPROGRAMS CALLED:                                            
C            UNIQUE:  GTPRED, SOLAR                                     
C            LIBRARY:                                                   
C              W4LIB:  ADVCT1, CIGVSB, DEPDIF, DIFADD, DIVG1, FIFTY,    
C                      FORIE1, GEOWND, GNDEX1, GTNRML, IHX, LIN, LIN2,  
C                      MAXMIN, MDIV, MONFQ, SLPRES, SPD1, STBL1, VORT1, 
C                      WIND, WTBLB1, FORIE2, MONFQ2, RHMEAN,            
C                      COMPDP, EPOTMP, LFTNDX, MLCL, MXRSPH, POTEMP,    
C                      QVCTR, RHSIVV, SWEATI, WSHEAR, ZEROMB,           
C                      THKBIN, HTZBIN, PCPINT                           
C                                                                       
C ATTRIBUTES:                                                           
C   LANGUAGE:  VS FORTRAN                                               
C   MACHINE:  NAS9000                                                   
C$$$                                                                    
      DIMENSION ID(2),FD(JJ,II),FD1(JJ,II),FD2(JJ,II),FD3(JJ,II),
     1 FD4(JJ,II),TEMP(NX),NDIR(NX,15)
      DIMENSION XX(1),FD5(JJ,II),FD6(JJ,II),FD7(JJ,II),FD8(JJ,II)
      INTEGER IBJ
      COMMON/M90201/JDATE,NCYCLE,MODP1,IG,JUNPK(8,4,7)
      DATA NOBS/X'700000'/,MASK2/X'FFF'/,MASK3/X'7'/
      DATA I80A/X'80A'/,ibj/0/
      ICND=0
      ITYPE=0
      J1=ID(1)
      J2=ISHFT(ID(2),-12)
      J1S=IAND(J1,MASK2)
      JHR=IAND(ID(2),MASK2)
      IDIF=IAND(ISHFT(J2,-12),MASK3)
C*******************                                                    
      IF(J1.EQ.NOBS)GO TO 111
C        NOTE THAT THIS SUBROUTINE IS CURRENTLY SET UP FOR 7 MODELS     
      GO TO (150,200,250,300,400,400,350),MODP1
C                                                                       
C******************* SUBROUTINES INVOLVING OBSERVATIONS HERE ***********
C                                                                       
C        COMBINED CIG/VIS                                               
 111              IF(J2.EQ.66.OR.J2.EQ.67)
     1 CALL CIGVSV(J1,J2,JHR,TEMP,FD1,NST,ICND,*902)
C        MAXMIN TEMPERATURE OBS. GUESS                                  
                  IF(J2.EQ.22)
     1 CALL MAXMNV(J1,J2,JHR,TEMP,FD1,NST,ICND,*902)
C                                                                       
C        SUBROUTINE TO PROCESS ALL OTHER OBSERVED PREDICTORS, INCLUDING 
C        THE DEW POINT DEPRESSION (J2=102) AND THE LOWEST OF THE        
C        OBSERVED 4-CAT (LIFR,IFR,MVFR,VFR) CIG OR VIS CONDITIONS       
C        CALL WAS MODIFIED TO ADD PREDICTOR 115 - OBVIS PREDICTOR       
C        INDICATING BLOWING PHENOMENA, HAZE, FOG, OR NONE               
C        (DALLAVALLE - 9/15/93)                                         
C        12/10/93 - CALL MODIFIED TO ADD OBS PREDICTORS                 
C        116 THRU 119 (TEMP/DEWPT AVG -116, FREEZING RAIN BIN - 117,    
C        SNOW BIN - 118, RAIN BIN - 119)                                
C        6/19/95 - CALL MODIFIED TO ADD OBS PREDICTORS                  
C        128 THRU 131 (BLOWING BIN - 128, HAZE BIN - 129, FOG BIN - 130,
C        PRECIP BIN - 131)                                              
                  IF((J2.EQ.102).OR.(J2.GE.113.AND.J2.LE.119)
     &              .OR.(J2.GE.128.AND.J2.LE.131))
     &     CALL OBSPRD(J1,J2,JHR,TEMP,FD1,FD2,NST,ICND,*902)
C                                                                       
C******************* SUBROUTINES INVOLVING MRF MODEL, STATION **********
C******************* CONSTANTS, OR HARMONICS ONLY HERE        **********
C                                                                       
C        SIN DOY, COS DOY, ETC.                                         
C        FORIE2 (SETTELMAIER - 4/92) INSERTED TO HANDLE PROJECTIONS     
C               OTHER THAN 0 (IE. MEDIUM RANGE PROJECTIONS).            
C                                                                       
 150              IF(J1.EQ.IHX(000400).OR.J1.EQ.IHX(000401).OR.
     1            J1.EQ.IHX(000402).OR.J1.EQ.IHX(000403)) THEN
                       IF(JHR.EQ.0) THEN
       CALL FORIE1(J1,TEMP,NST,ICND,*902)
                       ELSE
       CALL FORIE2(J1,JHR,TEMP,NST,ICND,*902)
                       ENDIF
                  ENDIF
C        EXTRATERRESTRIAL RADIATION OR 'CLEAR SKY' HOURS OF SUNLIGHT    
C                                                                       
      IF(J1.EQ.IHX(000425).OR.J1.EQ.IHX(000407).OR.J1.EQ.IHX(000424))
     1 CALL SOLAR(J1,JHR,FD1,TEMP,NST,XX,ICND,*902)
C                                                                       
C        MAX/MIN TEMPERATURE NORMALS                                    
C                                                                       
      IF((J1.NE.IHX(231476)).AND.(J1.NE.IHX(231477)))GO TO 155
      CALL GTNRML(J1,JHR,TEMP,FD,FD1,NST,XX,ICND,*902)
C                                                                       
C        STATION ELEVATION                                              
C                                                                       
 155              IF(J1.NE.IHX(231170)) GO TO 160
       CALL GTPRED(J1 ,JHR,FD,JJ,II,TEMP,2,XX,ICND,*902)
       GO TO 902
C                                                                       
C        LATITUDE                                                       
C                                                                       
 160              IF(J1.NE.IHX(231171)) GO TO 170
       CALL GTPRED(J1 ,JHR,FD,JJ,II,TEMP,2,XX,ICND,*902)
       GO TO 902
C                                                                       
C        LONGITUDE                                                      
C                                                                       
 170              IF(J1.NE.IHX(231172)) GO TO 350
       CALL GTPRED(J1 ,JHR,FD,JJ,II,TEMP,2,XX,ICND,*902)
       GO TO 902
C                                                                       
C******************* SUBROUTINES INVOLVING TJ MODEL ONLY HERE **********
C                                                                       
 200  CONTINUE
      GO TO 400
C                                                                       
C******************* SUBROUTINE INVOLVING LM MODEL ONLY HERE ***********
C                                                                       
 250  CONTINUE
      GO TO 400
C                                                                       
C******************* SUBROUTINES INVOLVING LP MODEL ONLY HERE **********
C                                                                       
 300  CONTINUE
      GO TO 400
C                                                                       
C******************* SUBROUTINES INVOLVING NGM MODEL ONLY HERE *********
C                                                                       
C        DEW POINT COMPUTATION                                          
C                                                                       
 350              IF(J1S.NE.IHX(021))GO TO 400
      CALL COMPDP(J1,JHR,FD,JJ,II,XX,0,ICND,*900)
      GO TO 900
C                                                                       
C******************* SUBROUTINES INVOLVING ANY MODEL HERE **************
C                                                                       
 400  CONTINUE
C                                                                       
C        EARTH-ORIENTED WINDS                                           
C                                                                       
                  IF(J1S.EQ.IHX(070).OR.J1S.EQ.IHX(071))
     1 CALL WIND(J1,JHR,FD,FD1,JJ,II,XX,ICND,*900)
C                                                                       
C                                                                       
C        50-PERCENT PREDICTORS                                          
C                                                                       
                  IF(ISHFT(IAND(J1,NOBS),-20).EQ.6)
     1 CALL FIFTY(J1,J2,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,TEMP,NDIR,NX,IPOS,
     2            NST,XX,ICND,*902)
C                                                                       
C                                                                       
C        INTERACTIVE LINEARIZED PREDICTORS                              
C                                                                       
                  IF(J1.EQ.IHX(120324).OR.J1.EQ.IHX(205324).OR.J1
     1            .EQ.IHX(121304).OR.J1.EQ.IHX(205320))
     2 CALL LIN(J1,J2,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,TEMP,NDIR,NX,IPOS,
     3 NST,XX,ICND,*902)
                  IF(J1.EQ.IHX(122304).OR.J1.EQ.IHX(123304).OR.
     1            J1.EQ.IHX(121324).OR.J1.EQ.IHX(206324).OR.
     2            J1.EQ.IHX(207324))
     3 CALL LIN2(J1,J2,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,TEMP,NDIR,NX,IPOS,
     4 NST,XX,ICND,*902)
C                                                                       
C        BINARY THICKNESS PREDICTOR (SETTELMAIER/JENSENIUS - 8/91)      
C        MODIFIED TEST FOR NEW ID'S (BOWER - 2/94)                      
C                                                                       
                  IF(J1S.GT.IHX(799).AND.J1S.LE.I80A)
     1 CALL THKBIN(J1,J2,JHR,FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        THICKNESS 700-1000 MB                                          
C                                                                       
                  IF(J1.EQ.IHX(160004))
     1 CALL DIFADD(IHX(160001),JHR,IHX(240001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        THICKNESS 700-850 MB                                           
C                                                                       
                  IF(J1.EQ.IHX(161004))
     1 CALL DIFADD(IHX(160001),JHR,IHX(205001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        THICKNESS 850-1000 MB                                          
C                                                                       
                  IF(J1.EQ.IHX(205004))
     1 CALL DIFADD(IHX(205001),JHR,IHX(240001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        THICKNESS 500-1000 MB                                          
C                                                                       
                  IF(J1.EQ.IHX(120004))
     1 CALL DIFADD(IHX(120001),JHR,IHX(240001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        THICKNESS 500-850 MB                                           
C                                                                       
                  IF(J1.EQ.IHX(121004))
     1 CALL DIFADD(IHX(120001),JHR,IHX(205001),JHR,FD,FD1,JJ,II,-1,
     2          XX,ICND,*900)
C                                                                       
C        THICKNESS 500-700 MB                                           
C                                                                       
                  IF(J1.EQ.IHX(122004))
     1 CALL DIFADD(IHX(120001),JHR,IHX(160001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        THICKNESS 300-700 MB                                           
C                                                                       
                  IF(J1.EQ.IHX(060004))
     1 CALL DIFADD(IHX(060001),JHR,IHX(160001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        THICKNESS 300-500 MB                                           
C                                                                       
                  IF(J1.EQ.IHX(100004))
     1 CALL DIFADD(IHX(060001),JHR,IHX(120001),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        2 M TEMPERATURE, INTERPOLATED FROM ISOBARIC LEVEL TEMPERATURES 
C        (WAS PART OF THE SEARCH FOR A COLD AIR DAMMING PREDICTOR)      
C                 (W. YAN - 5/94)                                       
C                                                                       
                  IF(J1.EQ.IHX(242020))
     & CALL CADPRD(J1,JHR,FD,FD1,FD2,FD3,FD4,FD5,FD6,FD7,FD8,
     &     JJ,II,XX,ICND,*900)
C                                                                       
C        G-INDEX                                                        
C                                                                       
                  IF(J1.EQ.IHX(205163))
     1 CALL GNDEX1(JHR,FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        BINARY TEMPERATURE PREDICTOR (SETTELMAIER/JENSENIUS - 8/91)    
C                                                                       
                  IF(J1S.GE.IHX(780).AND.J1S.LE.IHX(786))
     1 CALL TEMBIN(J1,J2,JHR,FD,FD1,JJ,II,XX,ICND,*900)
C                                                                       
C        SFC TEMP - SFC DEW PT                                          
C                                                                       
                  IF(J1.EQ.IHX(231022))
     1 CALL DIFADD(IHX(231020),JHR,IHX(231021),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        1000 MB TEMP - 1000 MB DEW PT                                  
C                                                                       
                  IF(J1.EQ.IHX(240022))
     1 CALL DIFADD(IHX(240020),JHR,IHX(240021),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        850 MB TEMP - 850 MB DEW PT                                    
C                                                                       
                  IF(J1.EQ.IHX(205022))
     1 CALL DIFADD(IHX(205020),JHR,IHX(205021),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        700 MB TEMP - 700 MB DEW PT                                    
C                                                                       
                  IF(J1.EQ.IHX(160022))
     1 CALL DIFADD(IHX(160020),JHR,IHX(160021),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        500 MB TEMP - 500 MB DP                                        
C                                                                       
                  IF(J1.EQ.IHX(120022))
     1 CALL DIFADD(IHX(120020),JHR,IHX(120021),JHR,FD,FD1,JJ,II,-1,
     2         XX,ICND,*900)
C                                                                       
C        300 MB TEMP - 300 MB DP                                        
C                                                                       
                  IF(J1.EQ.IHX(060022))
     1 CALL DIFADD(IHX(060020),JHR,IHX(060021),JHR,FD,FD1,JJ,II,-1,
     2         XX,ICND,*900)
C                                                                       
C        850 MB TEMP - 1000 MB TEMP                                     
C                                                                       
                  IF(J1.EQ.IHX(210420))
     1 CALL DIFADD(IHX(205020),JHR,IHX(240020),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        700 MB TEMP - 1000 MB TEMP                                     
C                                                                       
                  IF(J1.EQ.IHX(240420))
     1 CALL DIFADD(IHX(160020),JHR,IHX(240020),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        500 MB TEMP - 850 MB TEMP                                      
C                                                                       
                  IF(J1.EQ.IHX(205420))
     1 CALL DIFADD(IHX(120020),JHR,IHX(205020),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        700 MB TEMP - 850 MB TEMP                                      
C                                                                       
                  IF(J1.EQ.IHX(175420))
     1 CALL DIFADD(IHX(160020),JHR,IHX(205020),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        500 MB TEMP - 700 MB TEMP                                      
C                                                                       
                  IF(J1.EQ.IHX(160420))
     1 CALL DIFADD(IHX(120020),JHR,IHX(160020),JHR,FD,FD1,JJ,II,-1,
     2            XX,ICND,*900)
C                                                                       
C        1000 MB DEWPOINT DEP - 850 MB DEWPOINT DEP                     
C                                                                       
                  IF(J1.EQ.IHX(210427))
     1 CALL DEPDIF(IHX(240020),IHX(240021),IHX(205020),IHX(205021),JHR,
     2            FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        1000 MB DEWPOINT DEP - 700 MB DEWPOINT DEP                     
C                                                                       
                  IF(J1.EQ.IHX(240427))
     1 CALL DEPDIF(IHX(240020),IHX(240021),IHX(160020),IHX(160021),JHR,
     2            FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        850 MB DEWPOINT DEP - 700 MB DEWPOINT DEP                      
C                                                                       
                  IF(J1.EQ.IHX(175427))
     1 CALL DEPDIF(IHX(205020),IHX(205021),IHX(160020),IHX(160021),JHR,
     2            FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        850 MB DEWPOINT DEP - 500 MB DEWPOINT DEP                      
C                                                                       
                  IF(J1.EQ.IHX(205427))
     1 CALL DEPDIF(IHX(205020),IHX(205021),IHX(120020),IHX(120021),JHR,
     2            FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        1000 MB DEWPOINT DEP - 500 MB DEWPOINT DEP                     
C                                                                       
                  IF(J1.EQ.IHX(270427))
     1 CALL DEPDIF(IHX(240020),IHX(240021),IHX(120020),IHX(120021),JHR,
     2            FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        VORTICITY*10E5                                                 
C                                                                       
                  IF(J1S.EQ.IHX(107).OR.J1S.EQ.IHX(122))
     1 CALL VORT1(J1,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        DIVERGENCE*10E5(N.B.:THE CALL FOR ID 112 IS OBSOLETE AND       
C        SHOULD NOT BE USED)                                            
C                                                                       
                  IF(J1S.EQ.IHX(110).OR.J1S.EQ.IHX(112))
     1 CALL DIVG1(J1,JHR,FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        -2 * DIV-Q VECTOR*10E17 (BOWER - 7/90)                         
C                                                                       
                  IF(J1S.EQ.IHX(125))
     1 CALL QVCTR(J1,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,XX,ICND,
     2            FD5,FD6,FD7,FD8,*900)
C                                                                       
C        WIND SPEED                                                     
C                                                                       
                  IF(J1S.EQ.IHX(062))
     1 CALL SPD1(J1,JHR,FD,FD1,JJ,II,XX,ICND,*900)
C                                                                       
C        GEOSTROPHIC WIND - U, V, OR S                                  
C                                                                       
                  IF(J1S.EQ.IHX(672).OR.J1S.EQ.IHX(673).OR.J1S.EQ.
     1            IHX(663).OR.J1S.EQ.IHX(670).OR.J1S.EQ.IHX(671).OR.J1S.
     2            EQ.IHX(662))
     3 CALL GEOWND(J1,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        JETCLOUD BINARY PREDICTOR (HUGHES - 6/91)                      
C                                                                       
                  IF(J1S.EQ.IHX(751).OR.J1S.EQ.IHX(752).OR.J1S.EQ.
     1            IHX(753).OR.J1S.EQ.IHX(754).OR.J1S.EQ.IHX(755).OR.
     2            J1S.EQ.IHX(756).OR.J1S.EQ.IHX(757).OR.J1S.EQ.IHX(758))
     3 CALL JETCLD(J1,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,XX,ICND,FD5,FD6,*900)
C                                                                       
C        RELATIVE HUMIDITY BINARY PREDICTOR (SETTELMAIER - 6/91)        
C                                                                       
                  IF(J1S.EQ.IHX(760).OR.J1S.EQ.IHX(761).OR.J1S.EQ.IHX
     1            (762).OR.J1S.EQ.IHX(763).OR.J1S.EQ.IHX(764).OR.J1S.EQ.
     2            IHX(765).OR.J1S.EQ.IHX(766))
     3 CALL RHBIN(J1,J2,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        PRECIPITATION AMOUNT BINARY PREDICTOR (SETTELMAIER - 6/91)     
C                                                                       
                  IF(J1S.EQ.IHX(770).OR.J1S.EQ.IHX(771).OR.J1S.EQ.IHX
     1            (772).OR.J1S.EQ.IHX(773).OR.J1S.EQ.IHX(774).OR.J1S.EQ.
     2            IHX(775).OR.J1S.EQ.IHX(776).OR.J1S.EQ.IHX(777).OR.
     3            J1S.EQ.IHX(778))
     4 CALL PCPBIN(J1,J2,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        K-INDEX BINARY PREDICTOR (SETTELMAIER - 6/91)                  
C                                                                       
                  IF(J1S.EQ.IHX(790).OR.J1S.EQ.IHX(791).OR.J1S.EQ.IHX
     1            (792).OR.J1S.EQ.IHX(793).OR.J1S.EQ.IHX(794))
     2 CALL BINKI(J1,J2,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        VERTICAL VELOCITY BINARY PREDICTOR (SETTELMAIER - 7/92)        
C                  ADDED MORE CUTOFFS (ANTOLIK - 9/93)                  
C                                                                       
                  IF(J1S.GT.IHX(809).AND.J1S.LE.IHX(818))
     1 CALL VVBIN(J1,J2,JHR,FD,JJ,II,XX,ICND,*900)
C                                                                       
C          WIND SPEED BINARY PREDICTOR (GILBERT - 8/93)                 
C                                                                       
                  IF(J1S.GE.IHX(840).AND.J1S.LT.IHX(900))
     1 CALL WNDBIN(J1,J2,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        FREEZING RAIN PREDICTOR  (273-276 SMOOTH) (ERICKSON - 8/91)    
C                                                                       
                  IF(J1.EQ.IHX(121680))
     1 CALL ZRPRED(J1,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,XX,ICND,*900)
C                                                                       
C        LOGIT TRANSFORMS OF TEMPERATURE, THICKNESS (003 OR 019)        
C                 (ERICKSON - 5/92)                                     
C                                                                       
                  IF(J1S.EQ.IHX(003).OR.J1S.EQ.IHX(019))
     1 CALL LOGIT(J1,J2,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,TEMP,NDIR,NX,IPOS,
     2            NST,XX,ICND,*902)
C                                                                       
C                                                                       
C        K-INDEX OR TOTAL TOTALS                                        
C                                                                       
                  IF(J1.EQ.IHX(160162).OR.J1.EQ.IHX(120161))
     1 CALL STBL1(J1,JHR,FD,FD1,FD2,JJ,II,XX,ICND,*900)
C                                                                       
C        24-HR PRECIP AMOUNT                                            
C                                                                       
                  IF(J1.EQ.IHX(231132).AND.IDIF.EQ.5)
     1 CALL DIFADD(J1,JHR,J1,JHR-12,FD,FD1,JJ,II,1,XX,ICND,*900)
C                                                                       
C        SEA LEVEL PRESSURE                                             
C                                                                       
C                                                                       
                 IF(J1.EQ.IHX(241010))
     1 CALL SLPRES(IHX(240001),JHR,FD,JJ,II,XX,ICND,*900)
C                                                                       
C        MOISTURE DIVERGENCE*10E5                                       
C                                                                       
                  IF(J1S.EQ.IHX(114))
     1 CALL MDIV(J1,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        MODIFIED LIFTING CONDENSATION LEVEL (BOWER-7/90)               
C                                                                       
                  IF(J1S.EQ.IHX(168))
     1 CALL MLCL(J1,JHR,FD,FD1,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C        LIFTED INDEX (BOWER - 7/90)                                    
C                                                                       
                  IF(J1S.EQ.IHX(165))
     1 CALL LFTNDX(J1,JHR,FD,FD1,FD2,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C        EQUIVALENT POTENTIAL TEMPERATURE (BOWER - 7/90)                
C                                                                       
                  IF(J1S.EQ.IHX(024))
     1 CALL EPOTMP(J1,JHR,FD,FD1,FD2,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C        POTENTIAL TEMP (BOWER - 7/90)                                  
C                                                                       
                  IF(J1S.EQ.IHX(023))
     1 CALL POTEMP(ID,JHR,FD,FD1,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C         FREEZING LEVEL HEIGHT (IN MB) (BOWER - 7/90)                  
C                                                                       
                  IF(J1.EQ.IHX(101040))
     1 CALL ZEROMB(ID,JHR,FD,FD1,FD2,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C                                                                       
C         FREEZING LEVEL HEIGHT GRID BINARY (BOWER - 2/94)              
C                                                                       
                  IF((J1.EQ.IHX(101826)).OR.(J1.EQ.IHX(101827)).OR.
     1            (J1.EQ.IHX(101828)))
     2 CALL HTZBIN(J1,J2,JHR,FD,FD1,FD2,FD3,TEMP,JJ,II,
     3      XX,ICND,*900)
C                                                                       
C        A SET OF MULTIPLICATIVE PREDICTOR VARIABLES                    
C        VV * TT,KI,RH,MRH; RH * TT,KI  (BOWER - 7/90 & 6/91)           
C        VV * LAYER RH, VV * MEAN RH(1000-700 MB) *                     
C                       1000-850 MB GRID BINARY(1293 M) (BOWER - 2/94)  
C                                                                       
                  IF(((J1S.GE.IHX(711)).AND.(J1S.LE.IHX(717))).OR.
     1            ((J1S.GE.IHX(721)).AND.(J1S.LE.IHX(724))))
     2 CALL RHSIVV(J1,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C        INTERACTIVE PREDICTORS COMPUTED BY USING A GRID BINARY         
C        MULTIPLIER OF PRECIP. AMT. (0.01 INCHES) AND EITHER THE        
C        GRID BINARY OF THE FREEZING LEVEL (925 MB) OR THE              
C        VERTICAL VELOCITY AT A SELECTED LEVEL (BOWER - 2/94)           
C        FOR BOTH PREDICTOR TYPES, THE GRID BINARY OF THE FRZ LVL       
C        OR THE VERT. VEL. ARE AVERAGED OVER A 12-H PERIOD.             
C                                                                       
           IF((J1S.EQ.IHX(820)).OR.(J1.EQ.IHX(101821)))
     1 CALL PCPINT(J1,J2,JHR,FD,FD1,FD2,FD3,FD4,FD5,JJ,II,
     2             TEMP,XX,ICND,*900)
C                                                                       
C        MIXING RATIO/ SPECIFIC HUMIDITY (BOWER - 7/90)                 
C                                                                       
                  IF((J1S.EQ.IHX(037)).OR.(J1S.EQ.IHX(145)))
     1 CALL MXRSPH(J1,JHR,FD,FD1,FD2,JJ,II,TEMP,XX,ICND,*900)
C                                                                       
C                                                                       
C        WIND SPEED SHEAR (BETWEEN VARIOUS LEVELS) (BOWER - 7/90)       
C                                                                       
C            500 - 300 MB SHEAR                                         
C                                                                       
                  IF(J1.EQ.IHX(126077))
     1 CALL WSHEAR(IHX(120062),IHX(060062),JHR,FD,FD1,FD2,JJ,II,XX,
     2            ICND,*900)
C                                                                       
C            700 MB - 300 MB SHEAR                                      
C                                                                       
                  IF(J1.EQ.IHX(166077))
     1 CALL WSHEAR(IHX(160062),IHX(060062),JHR,FD,FD1,FD2,JJ,II,XX,
     2            ICND,*900)
C                                                                       
C            850 MB - 700 MB SHEAR                                      
C                                                                       
                  IF(J1.EQ.IHX(208077))
     1 CALL WSHEAR(IHX(205062),IHX(160062),JHR,FD,FD1,FD2,JJ,II,XX,
     2            ICND,*900)
C                                                                       
C            850 MB - 300 MB SHEAR                                      
C                                                                       
                  IF(J1.EQ.IHX(205077))
     1 CALL WSHEAR(IHX(205062),IHX(060062),JHR,FD,FD1,FD2,JJ,II,XX,
     2            ICND,*900)
C                                                                       
C            850 MB - 500 MB SHEAR                                      
C                                                                       
                  IF(J1.EQ.IHX(207077))
     1 CALL WSHEAR(IHX(205062),IHX(120062),JHR,FD,FD1,FD2,JJ,II,XX,
     2            ICND,*900)
C                                                                       
C            700 MB - 500 MB SHEAR                                      
C                                                                       
                  IF(J1.EQ.IHX(161077))
     1 CALL WSHEAR(IHX(160062),IHX(120062),JHR,FD,FD1,FD2,JJ,II,XX,
     2            ICND,*900)
C                                                                       
C        SWEAT-INDEX (BOWER - 7/90)                                     
C                                                                       
                  IF(J1.EQ.IHX(120167))
     1 CALL SWEATI(J1,JHR,JJ,II,FD,FD1,FD2,FD3,FD4,
     2             FD5,FD6,FD7,FD8,XX,ICND,*900)
C                                                                       
C        ADVECTION (MODIFIED CALL - BOWER - 7/90)                       
C                                                                       
                  IF(J1S.EQ.IHX(026).OR.J1S.EQ.IHX(106).OR.J1S.EQ.
     1            IHX(127).OR.J1S.EQ.IHX(031).OR.J1S.EQ.IHX(033)
     2            .OR.J1S.EQ.IHX(035).OR.J1S.EQ.IHX(036).OR.
     3            J1S.EQ.IHX(041).OR.J1S.EQ.IHX(046))
     4 CALL ADVCT1(J1,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,XX,ICND,*900)
C                                                                       
C        WET BULB TEMP                                                  
C                                                                       
                  IF(J1S.EQ.IHX(032))
     1 CALL WTBLB1(J1,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        HEIGHT OF DEWPOINT DEPRESSION (MILLER - 8/91)                  
C                                                                       
                  IF(J1S.GE.IHX(730).AND.J1S.LE.IHX(735))
     1 CALL HGTDD(J1,JHR,FD,FD1,FD2,JJ,II,TEMP,XX,ICND,IBJ,*900)
C                                                                       
C        TERRAIN INDUCED VERTICAL VELOCITY (BOWER - 2/94)               
C                                                                       
                  IF(J1S.EQ.IHX(054))
     1 CALL VDELZ(J1,JHR,FD,FD1,FD2,FD3,FD4,JJ,II,XX,ICND,*900)
C                                                                       
C        MEAN REL HUM OVER MODEL LAYERS (DALLAVALLE - 8/91)             
C        MEAN REL HUM OVER ADDITIONAL MODEL LAYERS (BOWER - 2/94)       
C                                                                       
                  IF(J1.EQ.IHX(229130).OR.J1.EQ.IHX(219130).OR.
     1            J1.EQ.IHX(209130).OR.J1.EQ.IHX(199130).OR.
     2            J1.EQ.IHX(169130).OR.J1.EQ.IHX(204130).OR.
     3            J1.EQ.IHX(159130).OR.J1.EQ.IHX(161130))
     4 CALL RHMEAN(J1,JHR,FD,FD1,FD2,FD3,JJ,II,XX,ICND,*900)
C                                                                       
C        MOS FORECASTS - (BOWER - 3/93)                                 
C                                                                       
                  IF(J1.EQ.IHX(802408).OR.J1.EQ.IHX(812408).OR.
     &               J1.EQ.IHX(801608).OR.J1.EQ.IHX(811608).OR.
     &               J1.EQ.IHX(801618).OR.J1.EQ.IHX(811618).OR.
     &               J1.EQ.IHX(820408).OR.J1.EQ.IHX(820418))
     & CALL MOSPRD(J1,JHR,TEMP,FD1,FD2,FD3,FD4,FD5,FD6,NST,XX,ICND,*902)
C                                                                       
C        RELATIVE FREQUENCIES                                           
C                                                                       
C        YEARLY FREQUENCIES(SNOW AMT.)                                  
C                                                                       
                  IF(J1.GE.IHX(231200).AND.J1.LE.IHX(231225))
     1 CALL GTPRED(J1,JHR,FD,JJ,II,TEMP,2,XX,ICND,*902)
C                                                                       
      IF(J1.GE.IHX(231200).AND.J1.LE.IHX(231225)) GO TO 902
C                                                                       
C        THE FOLLOWING CHECK WAS MODIFIED FROM AN UPPER LIMIT OF        
C        231475 TO 231614 TO ALLOW FOR NEW MONTHLY REL FREQUENCIES      
C        ID'S IN THE RANGE 231506 TO 231516 FOR TSTM AND SVR WX  AND    
C        IN THE RANGE 231601 TO 231614 FOR CEILING AND VISIBILITY       
C        RELATIVE FREQUENCIES.                                          
C        (BOWER, DAGOSTARO, DALLAVALLE, MILLER - 9/91)                  
C                                                                       
C        THE FOLLOWING CHECK WAS MODIFIED IN AUGUST 1995 TO CHANGE      
C        THE UPPER LIMIT FROM 231614 TO 231640 TO ACCOUNT FOR NEW       
C        SEASONAL RELATIVE FREQUENCIES.                                 
C        (DALLAVALLE - 8/95)                                            
C                                                                       
      IF(J1.LT.IHX(231410).OR.J1.GE.IHX(231640))GO TO 402
C                                                                       
C        CHECK FOR SEASONAL FREQUENCIES                                 
C                                                                       
      IF(J1.LE.IHX(231417))GO TO 375
      IF(J1.GE.IHX(231430).AND.J1.LE.IHX(231443))GO TO 375
      IF(J1.GE.IHX(231620).AND.J1.LT.IHX(231640))GO TO 375
C                                                                       
C        FREQUENCIES ARE MONTHLY                                        
C                                                                       
C        THE FOLLOWING IF TEST WAS ADDED TO CHECK FOR THE NORMAL        
C        MAX (231476) AND MIN (231477) TEMPERATURE.  THE TEST           
C        SHOULD BE REDUNDANT BECAUSE OF THE CHECK FOR THESE SAME        
C        PREDICTORS PRIOR TO THE CALL TO GTNRML                         
C                                                                       
C        MONFQ2 (SETTELMAIER - 4/92) INSERTED TO HANDLE PROJECTIONS     
C               OTHER THAN 0 (IE. MEDIUM RANGE PROJECTIONS).            
C                                                                       
      IF(J1.GE.IHX(231476).AND.J1.LE.IHX(231477))GO TO 402
                       IF(JHR.EQ.0) THEN
      CALL MONFQ(J1,TEMP,FD,FD1,NST,XX,ICND,*902)
                       ELSE
      CALL MONFQ2(J1,JHR,TEMP,FD,FD1,NST,XX,ICND,*902)
                       ENDIF
C                                                                       
C        FREQUENCIES ARE 2-SEASONAL                                     
C                                                                       
  375 J3=14
      MON=MOD(JDATE/10000,100)
C        MON=MONTH                                                      
      IF(MON.GE.4.AND.MON.LE.9)J3=13
      CALL GTPRED(J1,J3,FD,JJ,II,TEMP,2,XX,ICND,*902)
      DO 888 I=1,NST
	TEMP(I)=TEMP(I)*100.0
 888  CONTINUE
      GO TO 902
 402  ICND=1
 900  RETURN
 902  ITYPE=1
      GO TO 900
      END
