added analyseHour and changed Date-obj to Calendar-obj