A method for assessing the electrical function of a heart, a method for determining a subject's need for the implantation of an implantable cardioverter defibrillator or the need for administration of an anti-arrhythmic agent, and apparatus for assessing the function of the heart and a computer program product. The methods and products involve analysis of ECG.