I also act like this sometimes especially when going through a hard time and in the past it has caused my housemates to also feel like you have and wonder if they've done something wrong or whether I disliked them. Just think of it of them having a bad day. Try not to be in your head too much because you never know what someones going through in private. Maybe just asking them, checking in if they're ok is something that might be helpful for you both to clarify.
I'm personally now more aware of my actions and even if I don't want to greet my housemates or be sorta cheerful I try to at least say 'hi'. I'm lucky enough to now live with people who do their own thing so it suits my lifestyle better. I know some people prefer to have more sociable housemates but if this is the case with you, maybe its better to find that source else where. For some people home means having that private time with no social stressors, a recharge time. So don't take anything personally!