In the final six years of his life , Purcell wrote music for forty-two plays .
Purcell wrote several anthems for him during his life .