When I think of the people who have been angriest at me in my life, they're all people who (from my obviously-biased perspective) wronged me quite badly, and who I don't think I wronged at all.
Of course I might just be misunderstanding these particular situations: I think I did nothing wrong, but the other person thinks I did plenty wrong, and we just have completely different experiences of the situations. And this is a perfectly plausible option, but it's not a very deep or interesting one.
I think there’s a more interesting possibility: that we get angry at people exactly because we’ve wronged them. We’re angry at them for having shown us to be less-good than we want to imagine ourselves, and/or we want to retroactively make what we did to someone else ok by convincing ourselves that the person we were bad to "deserved" it
The second explanation – "my actions were retroactively ok because the person I did them to is Bad" – dovetails nicely into the Just World hypothesis: that in order to maintain a belief that the world is fair and that bad things can't happen to good people for no reason, when we hear about people suffering inexplicably we invent some reason why those people "deserve" it.
(If you've never read this article, I think it's one of the greatest feature pieces ever written, and has had a lot of influence on how I think about anger).
Still, there's something uniquely strange about tweaking the Just World hypothesis into "bad things can't happen to good people for no reason, so the bad thing I just did to someone must have been merited."
If you're going to suggest a theory like this, you obviously have to interrogate whether you also do the thing you're talking about.
Unsurprisingly, there’s no incidents in my life where I immediately think “yeah, I’m totally angry at that person because I did them wrong and I can’t accept it,” because if I realised that it would be hard to stay angry at them, and I would have to come to terms with my own misdeed instead
But I sat and thought for a bit about who I’m maddest about (or have been maddest about) for the “smallest” reason. It figures that maybe if I find someone I'm angry at where if I describe what I think they did wrong it's not ultimately something very serious, then potentially there's more going on in that situation.
As I kept thinking about it, I managed to think of a couple of people in my life who I've been very angry at and where I think you could tell a story that level of anger at them is a result of my own guilt about having wronged someone who didn't actually wrong me. Which is a strange thing to experience, and a difficult one, but maybe a helpful one.