# typenode properties #

![Type node icon](https://dataplatform.cloud.ibm.com/docs/content/wsd/nodes/scripting_guide/clementine/images/typenodeicon.png)The Type node specifies field metadata and properties\. For example, you can specify a measurement level (continuous, nominal, ordinal, or flag) for each field, set options for handling missing values and system nulls, set the role of a field for modeling purposes, specify field and value labels, and specify values for a field\.

Note that in some cases you may need to fully instantiate the Type node for other nodes to work correctly, such as the `fields from` property of the SetToFlag node\. You can simply connect a Table node and run it to instantiate the fields:

    tablenode = stream.createAt("table", "Table node", 150, 50)
    stream.link(node, tablenode)
    tablenode.run(None)
    stream.delete(tablenode)

<!-- <table "summary="typenode properties" id="typenodeslots__table_tkz_1zy_ddb" class="defaultstyle" "> -->

typenode properties  

Table 1\. typenode properties

| `typenode` properties       | Data type                                                                                                                                                                                                                                                                                                                | Property description                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       |
| --------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `direction`                 | `Input`  <br>`Target`  <br>`Both`  <br>`None`  <br>`Partition`  <br>`Split`  <br>`Frequency`  <br>`RecordID`                                                                                                                                                                                                             | Keyed property for field roles\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `type`                      | `Range`  <br>`Flag`  <br>`Set`  <br>`Typeless`  <br>`Discrete`  <br>`OrderedSet`  <br>`Default`                                                                                                                                                                                                                          | Measurement level of the field (previously  <br>called the "type" of field)\. Setting `type` to  <br>`Default` will clear any `values` parameter  <br>setting, and if `value_mode` has the value  <br>`Specify`, it will be reset to `Read`\.  <br>If `value_mode` is set to `Pass` or `Read`,  <br>setting `type` will not affect `value_mode`\.<br><br>The data types used internally differ from those visible in the type node\. The correspondence is as follows: Range \-> Continuous Set \- > Nominal OrderedSet \-> Ordinal Discrete\- > Categorical\. |
| `storage`                   | `Unknown`  <br>`String`  <br>`Integer`  <br>`Real`  <br>`Time`  <br>`Date`  <br>`Timestamp`                                                                                                                                                                                                                              | Read\-only keyed property for field storage type\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `check`                     | `None`  <br>`Nullify`  <br>`Coerce`  <br>`Discard`  <br>`Warn`  <br>`Abort`                                                                                                                                                                                                                                              | Keyed property for field type and range checking\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                         |
| `values`                    | \[*value value*\]                                                                                                                                                                                                                                                                                                        | For continuous fields, the first value is the minimum, and the last value is the maximum\. For nominal fields, specify all values\. For flag fields, the first value represents *false*, and the last value represents *true*\. Setting this property automatically sets the `value_mode` property to `Specify`\.                                                                                                                                                                                                                                                          |
| `value_mode`                | `Read`  <br>`Pass`  <br>`Read+`  <br>`Current`  <br>`Specify`                                                                                                                                                                                                                                                            | Determines how values are set\. Note that you cannot set this property to `Specify` directly; to use specific values, set the `values` property\.                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `extend_values`             | *flag*                                                                                                                                                                                                                                                                                                                   | Applies when `value_mode` is set to `Read`\. Set to `T` to add newly read values to any existing values for the field\. Set to `F` to discard existing values in favor of the newly read values\.                                                                                                                                                                                                                                                                                                                                                                          |
| `enable_missing`            | *flag*                                                                                                                                                                                                                                                                                                                   | When set to `T`, activates tracking of missing values for the field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `missing_values`            | \[*value value \.\.\.*\]                                                                                                                                                                                                                                                                                                 | Specifies data values that denote missing data\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `range_missing`             | *flag*                                                                                                                                                                                                                                                                                                                   | Specifies whether a missing\-value (blank) range is defined for a field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `missing_lower`             | *string*                                                                                                                                                                                                                                                                                                                 | When `range_missing` is true, specifies the lower bound of the missing\-value range\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `missing_upper`             | *string*                                                                                                                                                                                                                                                                                                                 | When `range_missing` is true, specifies the upper bound of the missing\-value range\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `null_missing`              | *flag*                                                                                                                                                                                                                                                                                                                   | When set to `T`, *nulls* (undefined values that are displayed as `$null$` in the software) are considered missing values\.                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `whitespace_ missing`       | *flag*                                                                                                                                                                                                                                                                                                                   | When set to `T`, values containing only white space (spaces, tabs, and new lines) are considered missing values\.                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `description`               | *string*                                                                                                                                                                                                                                                                                                                 | Specifies the description for a field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `value_labels`              | *\[\[Value LabelString\] \[ Value LabelString\] \.\.\.\]*                                                                                                                                                                                                                                                                | Used to specify labels for value pairs\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `display_places`            | *integer*                                                                                                                                                                                                                                                                                                                | Sets the number of decimal places for the field when displayed (applies only to fields with `REAL` storage)\. A value of `–1` will use the stream default\.                                                                                                                                                                                                                                                                                                                                                                                                                |
| `export_places`             | *integer*                                                                                                                                                                                                                                                                                                                | Sets the number of decimal places for the field when exported (applies only to fields with `REAL` storage)\. A value of `–1` will use the stream default\.                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `decimal_separator`         | `DEFAULT`  <br>`PERIOD`  <br>`COMMA`                                                                                                                                                                                                                                                                                     | Sets the decimal separator for the field (applies only to fields with `REAL` storage)\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `date_format`               | `"DDMMYY" "MMDDYY" "YYMMDD" "YYYYMMDD" "YYYYDDD" DAY MONTH "DD-MM-YY" "DD-MM-YYYY" "MM-DD-YY" "MM-DD-YYYY" "DD-MON-YY" "DD-MON-YYYY" "YYYY-MM-DD" "DD.MM.YY" "DD.MM.YYYY" "MM.DD.YYYY" "DD.MON.YY" "DD.MON.YYYY" "DD/MM/YY" "DD/MM/YYYY" "MM/DD/YY" "MM/DD/YYYY" "DD/MON/YY" "DD/MON/YYYY" MON YYYY q Q YYYY ww WK YYYY` | Sets the date format for the field (applies only to fields with `DATE` or `TIMESTAMP` storage)\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `time_format`               | `"HHMMSS" "HHMM" "MMSS" "HH:MM:SS" "HH:MM" "MM:SS" "(H)H:(M)M:(S)S" "(H)H:(M)M" "(M)M:(S)S" "HH.MM.SS" "HH.MM" "MM.SS" "(H)H.(M)M.(S)S" "(H)H.(M)M" "(M)M.(S)S"`                                                                                                                                                         | Sets the time format for the field (applies only to fields with `TIME` or `TIMESTAMP` storage)\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
| `number_format`             | `DEFAULT`  <br>`STANDARD`  <br>`SCIENTIFIC`  <br>`CURRENCY`                                                                                                                                                                                                                                                              | Sets the number display format for the field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| `standard_places`           | *integer*                                                                                                                                                                                                                                                                                                                | Sets the number of decimal places for the field when displayed in standard format\. A value of `–1` will use the stream default\.                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `scientific_places`         | *integer*                                                                                                                                                                                                                                                                                                                | Sets the number of decimal places for the field when displayed in scientific format\. A value of `–1` will use the stream default\.                                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `currency_places`           | *integer*                                                                                                                                                                                                                                                                                                                | Sets the number of decimal places for the field when displayed in currency format\. A value of `–1` will use the stream default\.                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `grouping_symbol`           | `DEFAULT`  <br>`NONE`  <br>`LOCALE`  <br>`PERIOD`  <br>`COMMA`  <br>`SPACE`                                                                                                                                                                                                                                              | Sets the grouping symbol for the field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   |
| `column_width`              | *integer*                                                                                                                                                                                                                                                                                                                | Sets the column width for the field\. A value of `–1` will set column width to `Auto`\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `justify`                   | `AUTO`  <br>`CENTER`  <br>`LEFT`  <br>`RIGHT`                                                                                                                                                                                                                                                                            | Sets the column justification for the field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
| `measure_type`              | `Range / MeasureType.RANGE`  <br>`Discrete / MeasureType.DISCRETE`  <br>`Flag / MeasureType.FLAG`  <br>`Set / MeasureType.SET`  <br>`OrderedSet / MeasureType.ORDERED_SET`  <br>`Typeless / MeasureType.TYPELESS`  <br>`Collection / MeasureType.COLLECTION`  <br>`Geospatial / MeasureType.GEOSPATIAL`                  | This keyed property is similar to `type` in that it can be used to define the measurement associated with the field\. What is different is that in Python scripting, the setter function can also be passed one of the `MeasureType` values while the getter will always return on the `MeasureType` values\.                                                                                                                                                                                                                                                              |
| `collection_ measure`       | `Range / MeasureType.RANGE`  <br>`Flag / MeasureType.FLAG`  <br>`Set / MeasureType.SET`  <br>`OrderedSet / MeasureType.ORDERED_SET`  <br>`Typeless / MeasureType.TYPELESS`                                                                                                                                               | For collection fields (lists with a depth of 0), this keyed property defines the measurement type associated with the underlying values\.                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `geo_type`                  | `Point`  <br>`MultiPoint`  <br>`LineString`  <br>`MultiLineString`  <br>`Polygon`  <br>`MultiPolygon`                                                                                                                                                                                                                    | For geospatial fields, this keyed property defines the type of geospatial object represented by this field\. This should be consistent with the list depth of the values\.                                                                                                                                                                                                                                                                                                                                                                                                 |
| `has_coordinate_ system`    | *boolean*                                                                                                                                                                                                                                                                                                                | For geospatial fields, this property defines whether this field has a coordinate system                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    |
| `coordinate_system`         | *string*                                                                                                                                                                                                                                                                                                                 | For geospatial fields, this keyed property defines the coordinate system for this field\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  |
| `custom_storage_ type`      | `Unknown / MeasureType.UNKNOWN`  <br>`String / MeasureType.STRING`  <br>`Integer / MeasureType.INTEGER`  <br>`Real / MeasureType.REAL`  <br>`Time / MeasureType.TIME`  <br>`Date / MeasureType.DATE`  <br>`Timestamp / MeasureType.TIMESTAMP`  <br>`List / MeasureType.LIST`                                             | This keyed property is similar to `custom_storage` in that it can be used to define the override storage for the field\. What is different is that in Python scripting, the setter function can also be passed one of the `StorageType` values while the getter will always return on the `StorageType` values\.                                                                                                                                                                                                                                                           |
| `custom_list_ storage_type` | `String / MeasureType.STRING`  <br>`Integer / MeasureType.INTEGER`  <br>`Real / MeasureType.REAL`  <br>`Time / MeasureType.TIME`  <br>`Date / MeasureType.DATE`  <br>`Timestamp / MeasureType.TIMESTAMP`                                                                                                                 | For list fields, this keyed property specifies the storage type of the underlying values\.                                                                                                                                                                                                                                                                                                                                                                                                                                                                                 |
| `custom_list_depth`         | *integer*                                                                                                                                                                                                                                                                                                                | For list fields, this keyed property specifies the depth of the field                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      |
| `max_list_length`           | *integer*                                                                                                                                                                                                                                                                                                                | Only available for data with a measurement level of either Geospatial or Collection\. Set the maximum length of the list by specifying the number of elements the list can contain\.                                                                                                                                                                                                                                                                                                                                                                                       |
| `max_string_length`         | *integer*                                                                                                                                                                                                                                                                                                                | Only available for typeless data and used when you are generating SQL to create a table\. Enter the value of the largest string in your data; this generates a column in the table that is big enough to contain the string\.                                                                                                                                                                                                                                                                                                                                              |
| `default_value_mode`        | `Read`  <br>`Pass`                                                                                                                                                                                                                                                                                                       | Set the default mode for all fields to `Read` or `Pass`\. The import node passes fields by default, while the Type node reads values by default\.                                                                                                                                                                                                                                                                                                                                                                                                                          |

<!-- </table "summary="typenode properties" id="typenodeslots__table_tkz_1zy_ddb" class="defaultstyle" "> -->

<!-- </article "role="article" "> -->