When selling a security for a loss it is the difference between the purchase price of a security and the price at which it was sold.