Tests whether String b is part of or equal to String a.
Syntax
IN(String a, String b)
Input
String a | is a string |
Domain type: | any Class or ID domain or system domain String |
String b | is a string |
Domain type: | any Class or ID domain or system domain String |
Output
IN returns: | a boolean value, i.e. True, False or undefined |
Domain: | system domain Bool |
Notes:
Tips:
Usable in
MapCalc, TabCalc, Simple calculators
Examples
Pocket line calculator examples:
? IN("VeryLongString","Long") |
returns True |
? IN("VeryLongString","long") | returns True |
? IN("ABC","123") | returns False |
MapCalc example:
Raster map Geomorphology uses class domain Geomorphology which contains among others the items "Glacial cirque", "Glacial lake", "Glacial slope" and "Glacial valley". To find all areas that are glacial, type on the command line of the Main window:
Glacial = IN(Geomorphology,"Glacial")
Geomorphology |
Glacial |
||||||||||||||||||
|
|
Legend |
|
al |
Active landslide |
gc |
Glacial cirque |
gl |
Glacial lake |
gs |
Glacial slope |
gv |
Glacial valley |
il |
Infilled lake |
ol |
Old landslide |
se |
Slope with minor erosion |
sf |
Steep slope near a fault |
Raster map Geomorphology has attribute table Geomorphology, in which class column Zonation contains several times the item "Steep slopes". To find all areas with steep slopes in map Geomorphology, type on the command line of the Main window:
Steep = IN(Geomorphology.zonation,"Steep")
Output map Steep will return True for all areas of the raster map Geomorphology where attribute column Zonation contains the string "Steep"; False will be returned for all other classes.
TabCalc example:
Glacial = IN(%K,"Glacial")
Steep = IN(Zonation,"Steep")
Domain |
|
|
|
Accumulation of debris on slope |
Steep slopes |
False |
True |
Active landslide |
Steep slopes |
False |
True |
Alluvial fan (flooding possible) |
Alluvial fan |
False |
False |
Alluvial fan (no flooding possible) |
Alluvial fan |
False |
False |
Dipslope |
Highest part |
False |
False |
Face slope |
Highest part |
False |
False |
Flat area near a fault |
Steep slopes |
False |
True |
Glacial cirque |
Highest part |
True |
False |
Glacial lake |
Highest part |
True |
False |
Glacial slope |
Highest part |
True |
False |
Glacial valley |
Highest part |
True |
False |
Heavily eroded area |
Steep slopes |
False |
True |
Hills near a fault |
Steep slopes |
False |
True |
Infilled lake |
Flat area |
False |
False |
Old landslide |
Steep slopes |
False |
True |
Ridge |
Steep slopes |
False |
True |
Slope with minor erosion |
Steep slopes |
False |
True |
Steep slope near a fault |
Steep slopes |
False |
True |
Valley in alluvial fan |
Alluvial fan |
False |
False |
See also:
STRGE |