Prophets of Science Fiction: Inspiration

Was the death of Mary Shelly's infant daughter that was the impetuous for her greatest work?