title: Heston model and estimation of the parameters
body: <p>I am trying to estimate the next volatility using the Ornstein-Uhlenbeck process and the CIR diffusion process.I read the following paper which explains how to find the parameters for the CIR process at page 13 and when I tried to compute my parameters I found out that it's not working with the CIR process(but strangely yes with the Vasicek Process).</p>
  <p>This is my python code to compute the parameters k,theta and xi:</p>
  <pre><code>B1=((T**-2)*((vt[1:])*(vt[:-1]**-1).sum()).sum()-(T**-1)*(vt[1:]*(vt[:-1]**-1)).sum())/((T**-2)*(vt[:-1]*(vt[:-1]**-1).sum()).sum()-1)
  kappa=-(1/dt)*np.log(B1)
  B2=((T**-1)*((vt[1:]*vt[:-1]**-1).sum())-B1)/((1-B1)*(T**-1)*(vt[:-1]**-1).sum())
  theta=B2
  B3=(T**-1)*(((vt[1:]-(vt[:-1])*B1-B2*(1-B1))**2)*vt[:-1]**-1).sum()
  xi=(2*kappa*B3)/(1-B1**2)
  </code></pre>
  <p>link to the paper :
  <a href="https://lib.dr.iastate.edu/cgi/viewcontent.cgi?article=16802&amp;context=rtd" rel="nofollow noreferrer">https://lib.dr.iastate.edu/cgi/viewcontent.cgi?article=16802&amp;context=rtd</a></p>
  <p>Thank you for your help</p>