Automatic detection of myocardial infarction through a global shape feature based on local statistical modeling