[Insight-users] Statistics: Find out coefficient of affine
	transform
    Luis Ibanez 
    luis.ibanez at kitware.com
       
    Sun May  6 12:25:01 EDT 2007
    
    
  
Hi Mathieu,
You may want to try the KalmanLinearEstimator.
http://www.itk.org/Insight/Doxygen/html/classitk_1_1KalmanLinearEstimator.html
Your estimator will be the vector [a,b],
and your measures will be the vector [1,Y]
The Kalman Linear Estimator should converge to the vector [a,b] that
minimizes the sum of squared errors between X and (a+bY).
For an example, you may want to look at:
     Insight/Testing/Code/Algorithms/
          itkKalmanLinearEstimatorTest.cxx
    Regards,
        Luis
---------------------------
Mathieu Malaterre wrote:
> Hello,
> 
>  I have a pretty simple problem to solve and I was wondering if I
> could reuse any brick already existing in ITK.
> 
>  I am working with a 4D dataset (x,y,y and theta), where I can
> express for each pixel that:
> 
> I(x,y,z)/sin(theta) = F(x,y,z) + b*I(x,y,z)/tan(theta)
> 
>  My goal here is to find out the b constant, I do not need the
> F(x,y,z) part. Obvisouly all I need to do is draw the line
> 
>   X = a + b Y
> 
> where X = I(x,y,z)/sin(theta) and Y = I(x,y,z)/tan(theta) and the
> slope will give me 'b'.
> 
> Any suggestions on which class to reuse ?
> thanks !
    
    
More information about the Insight-users
mailing list