What is the code to calculate the lowest margin and the highest margin level?

 

What is the code to calculate the lowest margin and the highest margin on which date and time tht it occur?



It should display something like example below on the chart:

Lowest margin: ??% on 01.02.2008

Highest margin: ??% on 01.05.2008

Reason: