string_to_array
Converts a comma_separated_string to an array of strings, long integers, or floats. This allows you to quickly write arrays of strings, floats, or (long) integers in the graph.
The string is split by commas and white space at either end of the substrings is stripped.
comma_separated_string: "2, 4, 6"
string_array: ["2", "4", "6"]
float_array: [2.0, 4.0, 6.0]
long_int_array: [2, 4, 6]White space at the start or end of the substrings is stripped.
comma_separated_string: "One string, two string "
string_array: ["One string", "two string"]Values that cannot be converted to integers or floats become zero values in the float or integer arrays.
Inputs
comma_separated_string
The port type is: string.
The string that gets processed into an array.
Outputs
string_array
The port type is: array<string>.
These are the split strings with whitespace at the start and end stripped.
float_array
The port type is: array<float>.
These are the split values converted to float. Unconvertible values become 0.0.
long_int_array
The port type is: array<long>.
These are the split values converted to float. Unconvertible values become 0.
