An implantable medical device (IMD) is implanted in a patient. The IMD uses a plurality of electrode vectors to generate intrathoracic impedance measurements. The intrathoracic impedance measurements can be indicative of amounts of intrathoracic fluid in the patient. An accumulation of intrathoracic fluid may indicate that the patient is at an increased risk of experiencing a heart failure event in the near future. The IMD performs a vector selection operation on a recurring basis. When the IMD performs the vector selection operation, the IMD uses impedance measurements to select one of the electrode vectors. The IMD can perform a risk assessment operation on another recurring basis. During performance of the risk assessment operation, the IMD uses impedance measurements of the selected electrode vector and/or other patient characteristics stored within the IMD to determine whether the patient is at an increased risk of experiencing a heart failure event.