Skip to main content

Relative beginner here! I'm trying to set up a workbench so it can take features, assign them groups and then assign sequential values per feature in a group. The Counter transformer does the first part but I need help with the second part. I've used the StatisticsCalculator transformer which adds sequential numbers but is there a way to add letters (e.g. a, b, c... and so on)? Or is there a way to do this in the text editor?

 

Thanks for any help!

You could use an AttributeValueMapper to map 0>a, 1>b etc

 

imageI don't know of any tools out of the box which would do this


This may vary based on encoding but...

 

You can use a ModuloCounter, set to max 26, and a CharacterCodeReplacer, in the standard ASCII set uppercase letters start go from 65 (A) to 90 (Z), lowercase ones from 97 (a) to 122 (z). So in your example, @Value(modulocount)+65 or @Value(modulocount)+97 would do the trick.


This may vary based on encoding but...

 

You can use a ModuloCounter, set to max 26, and a CharacterCodeReplacer, in the standard ASCII set uppercase letters start go from 65 (A) to 90 (Z), lowercase ones from 97 (a) to 122 (z). So in your example, @Value(modulocount)+65 or @Value(modulocount)+97 would do the trick.

This is a cool solution!


This is a cool solution!

Old computer skills to the rescue! 😂


Thanks for the help all, much appreciated!


Reply