; reference-based alignment ; number of particles x91=1254 ; number of reference images x92=2 ; last ring for rotational alignment x21=35 ; first ring for rotational alignment x22=5 ; Search range ; (the search for translation parameters will be ; restricted to +/- search range). x23=6 x24=1 ; create the selection document file. ; The image series is consecutive DOC CREATE select 1 1-x91 DOC CREATE selref 1 1-x92 ap mq ref*** selref x23,x24 x22,x21 sar**** select apmq101 ;rotate and shift images according to the parameters from AP MQ alignment do lb3 x55=1,x91 ud ic,x55,x41,x42,x43,x44,x45,x46 apmq101 if(x41.gt.0) then rt sq sar{****x46} ser{****x46} x43 x44,x45 else rt sq sar{****x46} _1 x43 x44,x45 mr _1 ser{****x46} y lb3 ud ice apmq101 en d