MIDLAND, TEX., NOV. 20 -- A smiling Jessica McClure, wearing a cast, teetered out of a hospital today, a month after the nation watched determined rescuers pull the toddler from an abandoned wellshaft where she had survived a grueling 58 1/2 hours.

The 19-month-old girl who was rescued Oct. 16 rode down a ramp at Midland Memorial Hospital in a toy wagon, then got out and tried out her cast with her parents.

"Thanks to the grace of God and some heroic men, we've got our baby back," said Jessica's father, Chip McClure, before the family got in a car and drove away.

McClure and his wife, Cissy, said they are looking forward to spending a happy Thanksgiving with the family reunited at home.

Holding a Winnie-the-Pooh bear and wearing a jacket bearing the name and seal of the Midland Police Department, Jessica waved to reporters and bystanders as she and her parents left.

After Jessica fell 22 feet through an eight-inch opening, volunteers dug through solid rock to reach her. She had been in Midland Memorial ever since.

Doctors feared they would have to amputate her right foot, which was jammed when she was trapped. But only the little toe was removed, and Dr. Shelton Viney said the girl's long-term prognosis is excellent.