Percy Bysshe Shelley was tutored by James Lind at Eton around 1809, when Percy would have been around 16. I can’t say whether or not Mary or Percy watched Lind perform any experiments before audiences/them in particular, but there’s no clear first-hand connection between what Lind was attempting and
Frankenstein.
Mary Shelley’s (née Mary Wollstonecraft Godwin) mother was Mary Wollstonecraft, author of
A Vindication of the Rights of Woman (1792) (she died of childbirth complications not long after). Though not quite given the education her mother advocated for for women, Mary Godwin was given an above-average education. Mary and Percy began a relationship in 1814 (Percy had a relationship with père Godwin and had agreed to bail him out of debt, despite having some hurdles to accessing his own future inheritance. Percy and Mary’s father fell out, but Mary and Percy fell in love when Mary was 16, and Percy was 21; he was married and estranged from his wife). Drama and pennilessness ensued. (Percy likely also had an affair with Mary’s stepsister, Claire, with whom they traveled to the Continent.) Mary became pregnant by Percy, during which period Percy’s estranged wife also had a son by him. Mary & Percy’s child was born 2 months premature in 1815 and died. In January 1816 she gave birth to his child, a boy. In 1816 they summered with Lord Byron (who had impregnated Claire by this point) in /near Geneva.
Sitting around a log fire at Byron's villa, the company amused themselves with
German ghost stories, which prompted Byron to propose that they "each write a ghost story".
[60][61]
During one mid-June evening, the discussions turned to the nature of the principle of life. "Perhaps a corpse would be re-animated", Mary noted; "
galvanism had given token of such things".
[63] It was after midnight before they retired, and unable to sleep, she became possessed by her imagination as she beheld the
grim terrors of her "waking dream", her ghost story:
[64]
“I saw the pale student of unhallowed arts kneeling beside the thing he had put together. I saw the hideous phantasm of a man stretched out, and then, on the working of some powerful engine, show signs of life, and stir with an uneasy, half vital motion. Frightful must it be; for supremely frightful would be the effect of any human endeavour to mock the stupendous mechanism of the Creator of the world.
[65][note 6]”
She began writing what she assumed would be a short story. With Percy Shelley's encouragement, she expanded this tale into her first novel,
Frankenstein; or, The Modern Prometheus, published in 1818.
[66] She later described that summer in Switzerland as the moment "when I first stepped out from childhood into life".
[56]
(See below for reference.)
In December of 1818, Percy’s wife suicided, and Mary and Percy (she would’ve been 18ish, he 23ish) married about 3 weeks later, in large part to bolster his efforts for custody of his children with his now-dead wife (he was ultimately ruled morally unfit for custody). In September 1817, Mary had another child, a girl, by Percy. Also during 1817, Mary finished
Frankenstein, which was published in early 1818.
They thereafter led a fairly itinerant life, and both children died young. Another child was begotten, more drama, Percy died sailing in 1822, and, along with two others, washed up on the shores near Viareggio, Italy.
More drama, and she ultimately died at the age of 53, suspected brain tumor.