The example you give reminds me greatly of a XKCD comic:
If you flip a light switch many times, you can find a strong correlation between flipping the light switch and the light turning on. As the comic suggests, this is not a causal relationship yet, just a correlation.
To become a causal relationship, the cause must be necessary and sufficient for the result to occur. The result should not occur without the cause, and if the cause occurs, so should the result. Sometimes we'll weaken this to just sufficient, meaning as long as the cause occurs, so does the result.
As far as the philosophy of science is concerned, this is a predictive act. When you associate the cause and effect, what you are in fact stating is that future causes will yield predictable future effects. This is, of course, impossible to prove, because nobody knows the future. However, in the philosophy of science, one strives to bring forward enough evidence that the events are causal such that one may come to believe they are truly causal through abduction.
Science's experimental methodology is designed to support this. Great care is taken to make it hard to mistake correlation for causality. This is at the heart of falsification. While a person may mistake correlation for causality, a second person repeating the experiment may falsify this mistaken conclusion.
The "nearness" effect is one that comes from our model of the world. We have a pretty good model of the world in our minds, most of the time. Most of the time things go as we expect them to. When they don't, we look for a "proximate cause." Scientifically, this always means a "local" cause in space and time. We're looking for some potion of the system whose state is not the state we predicted, right before we observed the effect. We assume "locality" because science has found a great deal of evidence to suggest it is true (like everything in science, all we can do is create a preponderance of evidence). This is such a well accepted assumption that when quantum entanglement suggested that the laws of the universe may in fact be non-local, this was received with quite a great deal of resistance. However, almost anything in science can be falsified, even deep rooted assumptions like this. With enough evidence, we have shown that quantum non-locality describes the experimental evidence well, while models which assume locality do not.
So those would be the three terms I would consider to answer your question: correlation, causality, and locality.