Include counting feature in anomaly detector

I am trying to set a feature for my detector but I want it to count the number of transactions in the selected field.
I only have the features sum (), max (), min () and avarage (). I don’t have a number field in my index that counts transaction by transaction, I don’t see it as viable. If you have any idea how to do this, something like counting fields of type String would save the project. Thanks for your help and comments.