From a Buddhist point of view, the actual experience of death is very important. Although how or where we will be reborn is generally dependent on karmic forces, our state of mind at the time of death can influence the quality of our next rebirth. So at the moment of death, in spite of the great variety of karmas we have accumulated, if we make a special effort to generate a virtuous state of mind, we may strengthen and activate a virtuous karma, and so bring about a happy rebirth.
To mix science up with philosophy is only to produce a philosophy that has lost all its ideal value and a science that has lost all its practical value. It is for my private physician to tell me whether this or that food will kill me. It is for my private philosopher to tell me whether I ought to be killed.
We cannot hope to die peacefully if our lives have been full of violence, or if our minds have mostly been agitated by emotions like anger, attachment, or fear. So if we wish to die well, we must learn how to live well: Hoping for a peaceful death, we must cultivate peace in our mind, and in our way of life.
Death be not proud, though some have called thee Mighty and dreadful, for thou art not so. For, those, whom thou think'st thou dost overthrow. Die not, poor death, nor yet canst thou kill me.