15.42 IF

IF|IFNOT [.AND.|.OR.] [.NOT.] [DATA] [ERROR] [INTERACTIVE] [MESH] [THREE|3D] [value {.LT.|.EQ.|.GT.|.LE.|.NE.|.GE.} value] The condition is tested and if satisfied the rest of the line up to the semicolon ";" is executed. If not satisfied it is skipped. If .AND. or .OR. are omitted .AND. is assumed. IF|IFNOT [conditions] THEN . . . ELSE . . . ENDIF If the tested condition is satisfied lines up to the ENDIF or ELSE are executed. Otherwise they are skipped. 1. DATA - True if any data points are available. 2. ERROR - This condition is true if the last line had an error. 3. INTERACTIVE - True if the program is running interactively, False if it is run in BATCH mode. The device you are using may or may not be interactive independent of the mode of operation. 4. MESH - True if the data is (3D) mesh data. 5. 3D - True if 3D is turned on. You should notice that mesh data may be plotted as flat or 3D data. 6. value - Any number or lexical. Example TD:IF MESH PLOT;IFNOT MESH HISTOGRAM; or... TD:IF MESH THEN;PLOT;ELSE;HISTOGRAM;ENDIF; If the current data is mesh data it is plotted as a scatter plot otherwise it is histogrammed. TD:IF 3D .AND. V_SUM .GT. 0 HISTOGRAM Histograms 3-d data if it is greater than zero. TD:IF V_SUM .GT. 0 .OR. V_SUM .LT. -1 .AND. 3D JOIN Joins mesh data if the sum over the data is not between -1 and 0.