Option to select energy range added (+ minor modifications)