A morbid topic, but I came across a discussion on bogleheads about how to die. It posted a link to this article titled How Doctors Die.
It’s not a frequent topic of discussion, but doctors die, too. And they don’t die like the rest of us. What’s unusual about them is not how much treatment they get compared to most Americans, but how little. For all the time they spend fending off the deaths of others, they tend to be fairly serene when faced with death themselves. They know exactly what is going to happen, they know the choices, and they generally have access to any sort of medical care they could want. But they go gently.It's a sobering article worth a read.
Closely related are Death with Dignity laws. As of this writing, five states have laws for this -- California, Colorado, Oregon, Vermont, and Washington.