PRO parashift,cube3,dopvel ; ; Doppler velocity measurement using 7-point line-centre ; parabolic fit. ; INPUT: CUBE3 - float data cube [x,y,lambda], i.e. 1 scan of GFPI ; OUTPUT: DOPVEL - 2D Doppler map in km/s ; calib=2.843 ;km/s per step, lambda=8542.14 A, 1 step=0.081 A zeropos=17 ; line centre position (step) si=size(cube3) dopv=fltarr(si[1],si[2]) ; lambda range +/- 3 points around zero position st1=zeropos-3 st2=zeropos+3 x=findgen(7)-3. xx=rebin(x,280) ;refining 40x (sensitivity 2.843/40=0.07 km/s) xx=xx(0:240) for j=0,si[2]-1 do begin for i=0,si[1]-1 do begin y=reform(cube3[i,j,st1:st2]) ;7-point profile p=POLY_FIT(x,y,2) yy=p[0]+p[1]*xx+p[2]*xx*xx ; p[2]>0: absorption; p[2]<0: emission if p[2] gt 0 then mm=min(yy,pos) else mm=max(yy,pos) dopv[i,j]=float(pos) endfor endfor dopvel=(dopv-120)*calib/40. END