Hello and welcome. I am sorry to hear about this criticism.
I don't really see this comment as age discrimination, at least not on its face. Certainly, there can be a correlation between between older and being unable to grasp new concepts, but the two things are distinguishable, and in general it is not illegal to take adverse employment action against an employee due to the latter. In other words, while an "inability to learn" may correlate with age, the ability to learn is a vital skill in the workplace, and if your employer perceives you as lacking in that skill--rightly or wrongly--they can take action on that basis.
To prevail on an age discrimination claim, you would need to prove that the same adverse employment action would not be taken against a younger employee performing identical to you. Now, if the junior analysists you speak of are no quicker at "learning" things than you, or are making the same mistakes but not being criticized, THAT might be evidence of age discrimination, but you really need something like this. The comment you describe on its own would typically be insufficient to establish that you are being treated different because of how old you are because, simply put, the comment is not attacking your age it is criticizing your ability, and employers always have the freedom to judge ability.
I would keep a close eye out for any other comments or actions which evidence an intent to discriminate against you because of how old you are. A pattern of unfair treatment toward other older employees, derogatory comments about your age, younger employees being cut less slack, etc. Document these things and you may be able to build a stronger case for age discrimination. This singular comment, though, would probably not be enough.
I hope this helps. Please let me know if I can be of any further assistance to you.