In a disk drive, a contact write current that causes head-disk contact due
to pole tip protrusion is detected using a variance of a position error
signal (PES). A method of determining the contact write current includes
generating PES's in response to the head reading servo sectors on the
disk, calculating PES variances wherein each PES variance is a
statistical measure of a different group of the PES's, calculating a
change in the PES variances, and selecting the contact write current in
response to the change in the PES variances.