There are a lot of things that can influence a woman's behaviour to you. I'm gonna give you an example. My girlfriend is always more closed when she's in her parents house. If she's there, we'll have sex 3 times a week, maybe a bit more. When she's somewhere else (my house or hers) we'll do it almost everyday. Not only that, but she's way more attentive, caring and loving when she's not there too. I think that the place just makes her blue.
Of course it's not always something like that, it can also be a phase, something that is going on in her life, her job, her friends getting engaged or marrying (as the gentlemen mentioned above). A series of factors can be influencing a woman's behaviour.
The thing that I must mention is: don't get out of your center, and never stop being loving and caring about her. Why? Because when you change your action towards her she knows that she can change you based on how she acts towards you. The main thing is: if you made a promise to YOURSELF of being a loving, caring and the best boyfriend you can be (do not misundestood it as a bootlicker, being the best you can be has nothing about getting out of your way like a puppy and always doing what she wants) then that's what you're gonna be. Doesn't matter if she' angry, cold on you, whatever. You open her up with your humour and your good mood. It's not always that you can open her up, but it doesn't mean you'll stop doing that.
Now the second thought is: if I should keep on acting on my good, should I pretend as if nothing is happening? Absolutely no. You're a man, your natural gift is solving problems, breaking walls. If you're feeling that she's cold on you for sometime (women usually get cold for one day, two, maybe a week depending on what's going on in a natural way, if it's more than that you should be "worried") you call her, let her sit down by your side, hold her hand and say "Honey, I noticed that you've been a bit cold and distant lately. Is something going on?" and let her talk. Men have a 6th sense on that, we know when there's something wrong with our women. If you know there's something wrong and she doesn't tell you, keep on asking her. Get her to talk. Do not interrupt her, and keep on asking good quality questions. If she's complaining about something you did (which you'll analyse and judge if she's right or if it's something she misunderstood about you), about something in her life, about her friends... doesn't matter. Listen to your woman, let her open her heart for you, let her tell you everything, and when you feel that there's more you can keep on asking, making sure you understand what she means (because she will be expecting you to).
The rules you should always bring for yourself in the relationship are:
1) I won't ever, by any case, change my attitude (unless it's for a better version of myself)
Excellence is an habit, and it's not because she's good that she can change me. It's preferable to breakup (that I recommend on extreme circunstamces such as cheating, infidelity, continuous disrespectful behaviour, etc) than to change yourself. Do not be a puppy, also do not be distant and indifferent to everything about her. Be her man, be her mountain, her stronghold.
2) I'm here to solve problems, not to make them
It also fits in the "do not change your attitude" thing. Changing yourself will always bring more problems than solving them (supposing that you're acting like a good man, not like a weak beta or a sh!t ass "indifferent alpha"). If there's a problem, you solve them. Communication in a relationship is the key. Arguing isn't communicating. You must be able to listen to her, understand her (I didn't mean accepting) what she says and finding solutions for the problems. She's your woman, and she trusts your leadership. If the boat if sinking, they will blame the Captain, not the Sailor.