I want to know how many digits do I have in a text variable. For example, a function that in the text "ABC234" the answer would be 3.
I tried with this:
aa=gregexpr("[[:digit:]]+\\.*[[:digit:]]*","ABC234")
I almost have it, but honestly I still dont understand the lists, so I have no idea how to get it.
Any function? Or how to manage it with my almost-option?
Thanks