The book's preface, by Percy Shelley writing from Mary's perspective, originates the legendary 'ghost-story competition' account of Frankenstein's conception. In 1816 the couple had travelled to Switzerland to summer with celebrated philanderer and poet George Byron, along with and at the urging of Mary's stepsister Claire Clairmont who was pregnant with his child. Byron rented one 'Villa Diodati' on the scenic shores of Lake Geneva, but worldwide atmospheric disturbance from the volcanic eruption of Mt. Tambora in Indonesia caused an abnormally "cold and rainy" (p.4) season which forced the party to stay indoors and amuse themselves by composing ghoulish horror stories.
Although the preface describes Shelley's novel as the only completed product of the contest, a year later Byron's physician John William Polidori expanded his patron's fragment into a novella of his own - one of the first works to depict The Vampyre as a suave, myserious aristocrat.
A more elaborate account of the contest is given in Mary Shelley's 'Introduction' to the 1831 edition of 'Frankenstein'
Online edition of Lord Byron's 'Fragment of a Novel', (1816)
Online edition of John William Polidori's expansion of it 'The Vampyre', (1819)