Function returns the medRQ, defined in Andersen et al. (2012).
Assume there is \(N\) equispaced returns in period \(t\). Let \(r_{t,i}\) be a return (with \(i=1, \ldots,N\)) in period \(t\).
Then, the medRQ is given by
$$
\mbox{medRQ}_{t}=\frac{3\pi N}{9\pi +72 - 52\sqrt{3}} \left(\frac{N}{N-2}\right) \sum_{i=2}^{N-1} \mbox{med}(|r_{t,i-1}|, |r_{t,i}|, |r_{t,i+1}|)^4
$$