Office relationships can be tricky to navigate. Is your boss tired or frustrated? Is that one coworker stressed in a don’t-bother-me way or are they just waiting for someone to offer them help? A little introspection might help you better decode what’s going on in their minds. According to a recent study published in the journal Cognitive Enhancement, the better you are at understanding yourself, the better you’ll be at parsing out other people’s states of mind.

Psychologists from Wurzburg University in Germany put 161 participants through a three month training program designed to help them better identify their own “sub personalities,” according to a Science of Us piece about the research. These varying parts of our inner selves include “happy parts,” “inner critics” and our “vulnerable parts.” The participants who improved the most at identifying their sub personalities over the course of the training also showed the biggest improvement in interpreting other people’s mental states.

Interestingly, this link between having a better understanding of your own mental states and those of others proved especially true when it came to negativity. Participants who could readily identify the negative parts of their own personalities could more easily pinpoint those mental states in others, too. This is important to note considering research shows that the ability to embrace negative feelings (instead of suppressing or ignoring them) is good for your wellbeing.

Lead study author Anne Böckler, a professor at Wurzburg University and research associate at the Max Planck Institute for Human Cognitive and Brain Sciences, summed up the findings to Science of Us: “Expanding our knowledge about internal dynamics such as our thoughts, beliefs, or emotional patterns, allows for a better understanding of these processes in others.”

These findings suggest that getting better at decoding other people’s mental states—and improving your interactions with them in the process—might hinge on how well you understand yourself. No matter what your job is, it likely entails some level of collaboration or communication with others. And despite what seems like a growing trend of making interpersonal interactions as infrequent as possible outside of work, it’s important to know how to connect with your fellow humans. This is good motivation to schedule some self-reflection time today.

Read the study here.