About cookies on this site Our websites require some cookies to function properly (required). In addition, other cookies may be used with your consent to analyze site usage, improve the user experience and for advertising. For more information, please review your options. By visiting our website, you agree to our processing of information as described in IBM’sprivacy statement. To provide a smooth navigation, your cookie preferences will be shared across the IBM web domains listed here.
Last updated: Feb 11, 2025
The SetToFlag node derives multiple flag fields based on the
categorical values defined for one or more nominal fields.
Example
node = stream.create("settoflag", "My node") node.setKeyedPropertyValue("fields_from", "Drug", ["drugA", "drugX"]) node.setPropertyValue("true_value", "1") node.setPropertyValue("false_value", "0") node.setPropertyValue("use_extension", True) node.setPropertyValue("extension", "Drug_Flag") node.setPropertyValue("add_as", "Suffix") node.setPropertyValue("aggregate", True) node.setPropertyValue("keys", ["Cholesterol"])
properties |
Data type | Property description |
---|---|---|
|
[category category category]
|
|
|
string | Specifies the true value used by the node when setting a flag. The default is
. |
|
string | Specifies the false value used by the node when setting a flag. The default is
. |
|
flag | Use an extension as a suffix or prefix to the new flag field. |
|
string | |
|
|
Specifies whether the extension is added as a suffix or prefix. |
|
flag | Groups records together based on key fields. All flag fields in a group are enabled if any record is set to true. |
|
list | Key fields. |
Was the topic helpful?
0/1000