Hi Steve,
I think the StatisticsCalculator transformer is suitable to this case rather than the ListHistogrammer.
For example, if you set the parameters of the StatisticsCalculator like this:
Attributes To Analyze: Attribute1 User
Histogram List Attribute: histogram
the output feature (SUMMARY) will have these list attributes. Attribute1.histogram{}.value
Attribute1.histogram{}.count
User.histogram{}.value
User.histogram{}.count
Then, you can get the value-count pairs of each attribute (Attribute1 and User) from these lists.
Finally, if you need to create concatenated string like "Attribute1, Value 1, 3, Value 2, 99, ...", a PythonCaller with this Python script (for example) would work.
-----
import fmeobjects class FeatureProcessor(object): def __init__(self): pass def input(self, feature): attrNames = r'Attribute1', 'User'] for attr in attrNames: values = feature.getAttribute('%s.histogram{}.value' % attr) counts = feature.getAttribute('%s.histogram{}.count' % attr) s = attr for (v, c) in zip(values, counts): s += ', Value %s, %s' % (v, c) newFeature = feature.cloneAttributes() newFeature.setAttribute('attr_value_count', s) self.pyoutput(newFeature) def close(self): pass -----
Takashi
Many Thanks for your input Takashi,
yes this is perfect.
I appreciate your python code also. I know python but am not that good at intergrating it with FME yet !!
Thanks Again
Steve