A contingent fee agreement shall be in writing and shall state the method by which the fee is to be determined, including the percentage or percentages that shall accrue to the lawyer in the event of settlement, trial or appeal, and the litigation and other expenses to be deducted from the recovery.