Just because there is no evidence that a God does anything to help (or even exists), we can't say that the activity of prayer doesn't seem soothing at all. It may be true that no real help may come from such a God, but the activity of prayer itself, might soothe the heart.
If we as Buddhists deny this or refuse to accept it, just because of "lack of evidence", we don't stand on very firm ground. In fact, there are many atheists and agnostics who claim that Buddhist meditation also doesn't have any of the positive effects that Buddhists attribute to it. Again, while the scriptures positively assert that in the fourth jhāna one can gain supranormal powers, many people scoff at these claims. Even some secular Buddhists say that such ideas are implausible. They too stake their claims on the lacuna of direct evidence.
That said, prayer is not the only way to soothe the heart. It is one of the ways. And it is not without serious dangers and pitfalls. Before I come to these, let me briefly talk about the ways of dealing with sudden sorrow, and briefly talk about the ways outlined in Theravada Buddhism.
A survey of ways to soothe the heart
Beings have invented a variety of techniques that help take the mind off of sudden grief and sorrow.
Activities such as drinking, smoking, adultery, etc. are the worst ways of dealing with pain. Even though they take the mind off the sorrow, they lead to regret, unhappiness, and ultimately to self-destruction - thus they are morally dark kamma. Incidentally, while some atheists or agnostics would recommend these activities, a Buddhist would never recommend these ways at all. In this sense, Buddhists are NOT your regular atheists.
Now come the morally neutral activities: really, prayer and calling God for help can be merely classed along with traveling, listening to music, reading books or poetry, or engaging in some hobby. This does not mean that a Buddhist would recommend prayer - it is just morally neutral, and takes the mind away from the sorrow temporarily. One may choose to use these if one sees them fit, but then again, one's judgement may not be very strong when struck by sudden sorrow. So these activities could even become a delusional prelude to something worse. Tread carefully when using these methods. We'll come to the pitfalls and dangers in a bit.
A better thing to do would be to engage in morally bright activities that can also take the mind off the sudden grief at the same time. This is what a Buddhist would recommend. Activities such as volunteering, donations, and community service are morally bright activities and help alleviate mental suffering, give the mind a sense of high self-esteem, and lighten the heart.
Theravada Buddhist Ways of soothing the heart
I listed above some morally bright activities that can take the mind off sudden grief. Many of these can be done by even non-Buddhists, but some of these are usually considered to be "Theravada Buddhist" methods. Although you don't have to be a Theravada Buddhist to try any of these, one could say so with due respect to the tradition that preserved these. It simply involves asking for advice and listening to stories of people that dealt with similar circumstances in a better way. This helps one take courage from the lives of such people.
Thus one can recollect the stories of the Buddha, his disciples, modern monks who faced similar circumstances, and even lay people among us that could serve as good examples. This sort of recollection (anussati) is the best recommended strategy for dealing with sudden grief. From my own personal experience, even before I turned a Buddhist, I remember that the act of crying and praying was not as useful as someone pointing out examples of people that achieved despite the odds stacked up against them, and despite repeated loss. I am especially thankful to my mother for doing that when I was a young despondent teenager.
In fact the whole of the Buddha's teaching is about providing a good example of a person that managed stress very skillfully. The Buddha says that there are two basic responses one may have to the web of samsāra and dukkha: a) bewilderment, b) seeking someone that knows a way or two out of this suffering. The Buddha's teaching supports precisely this second response.
Traditionally, there is the list of ten recollections, and at least the first four recollections - buddhānussati, dhammānussati, sanghānussati, devānussati - are truly activities of recollections that can lighten the heart. (I'll not go into details of how one uses these meditations. If you're not familiar with them, I recommend reading the book "A meditator's tools" - by Thānissaro Bhikkhu)
But this is not all! The other six reflections (6 satis in the ten recollections group) can also have a soothing effect on the heart if used skillfully. A young Indian boy named Venkataramana lost his father, whom he admired and loved a lot. In his grief, he recollected how his father's body had become upon death. He considered how it would be if he too were to die. He imagined his own body as dead, and reflected on the imminent possibility of death. While to some of us, this sort of thinking could drive us into depression, young Ramana became cool, and calm, entered meditative states and decided to renounce everything and search for inner peace. He went on to become one of the most famous spiritual masters of 20th century Asia: Sri Ramana Maharishi.
So the methods of practice that the Buddha recommended work even for non-Buddhists. You don't have to be a Buddhist for these methods to work. You only have to be skillful in using them. What's more: Theravada Buddhism offers a whole array of techniques. In fact the whole religion is about dealing with suffering.
Dangers and pitfalls of petitionary prayer
It doesn't matter if the one prayed to, is imaginary or not, or is even capable of helping or not. Even if one were to pray to one's political ruler (who may be living), and ask for help, there are significant dangers and pitfalls involved in the act of prayer and important reasons to be extremely careful. For brevity, I shall list only two dangers and two pitfalls, although there are many more.
Danger 1: Justified aversion
When one sees oneself as a victim in need of help, one could see someone else as a villain. This could be anything between one that really makes fun of you in your misery, to one that is just indifferent to your misery. All of them are seen as villains. And these people can be the target of our aversion. We can see this tendency in almost every single religious lore.
In Numbers 31:1-4:
And the LORD spake unto Moses, saying, Avenge the children of Israel
of the Midianites: afterward shalt thou be gathered unto thy people.
And Moses spake unto the people, saying, Arm ye men from among you for
the war, that they may go against Midian, to execute the LORD'S
vengeance on Midian. Of every tribe a thousand, throughout all the
tribes of Israel, shall ye send to the war.
Even in the Mahabharata the battle of Kurukshetra is justified as it is said to be done for the "establishment of Dharma". The Pandavas who patronize Krishna (considered God by the Hindus) avenge their humiliation, and even claim that God is on their side. Even killing one's grandfather and teacher are justified under the guise of social duty (caste duty for kshatriyas).
Even Germany justified starting WWII by reminding the world of the humiliation they had to undergo in 1919. And the people of Germany looked on for a savior. That this savior (Fuhrer) happened to be human doesn't make much difference - the people's attitude was that of praying to this savior to help Germany. And in the process, they justified everything this savior did.
Danger 2: Being beguiled
In some cases, one may talk to a priest that may recommend a particular expensive religious service, where the religious body may benefit, but really gives little solace to the sponsor. Some may not see much danger in this, but the first danger is in trusting a person that makes a business out of people in distress. If the priest makes a business out of such activities, he is not gaining merit from the prayer - instead it can be dangerous for him. And if the sponsor pays his respects to such a misled priest it can be equally dangerous to him.
Additionally, some priests get you to perform some rituals - such as sacrificing an animal. Believing that such acts would help, one engages in what is actually dangerous kamma. And such kamma is detrimental in the long term, whether or not one is aware that it is immoral.
Pitfall 1: Breeds non-chalance and heedlessness
In a few cases, our misfortune is caused by our own stupid actions. In those cases, it is very important to learn from one's experience. Petitionary prayer could lead to complacency and heedlessness (pamāda). The last words of the Buddha were about heedfulness (appamāda).
Pitfall 2: Deceptive consolation
Prayer and crying on someone's shoulder (whether virtual or real) could have the effect of generating self-pity and a growing sense of entitlement for self-pity. If one's parents or children die, grief is but inevitable. And people might even feel sympathy. But sometimes, people grieve just to win sympathy. The act of prayer feeds the mind's tendency to wish for sympathy.
A donation made out of free will, as an expression of one's gratitude for the guidance provided is totally different from payment for a religious service meant to soothe the heart. The act of donating gives a sense of wealth. But the act of payment for a prayer service at a religious institution reinforces a sense of poverty and self-pity.
Conclusions
Prayer may be a morally neutral activity, but has some serious pitfalls that easily delude the psychologically weak. Instead of praying for help, it is much better to engage in activities such a donating, community service, volunteering, or even hearing stories of people that faced similar circumstances, and learning lessons from them. These activities can renew one's energy, lift one's mood, keep one engaged, and also enter deep states of concentration, which can act as a platform for developing insight and attain full liberation from all suffering.