frameDist              package:EBImage              R Documentation

_C_a_l_c_u_l_a_t_e _p_a_i_r_w_i_s_e _d_i_s_t_a_n_c_e_s _b_e_t_w_e_e_n _i_m_a_g_e _f_r_a_m_e_s _o_r _f_r_a_m_e_s _o_f _t_w_o _i_m_a_g_e_s

_D_e_s_c_r_i_p_t_i_o_n:

     Given two images with multiple frames, 'frameDist' calculates a
     matrix of distances between frames (the more similar are the
     images, the smaller are the distances). Prerequisite: images
     should be centered and rotationally and scale aligned. The
     function is recommended with 'stackObjects' with arguments
     'rotate=combine=TRUE'.

_U_s_a_g_e:

       ## S4 method for signature 'Image, Image':
       frameDist(x, y, r, g, b, blur=TRUE, 
           method="dist", verbose, ...)
       ## S4 method for signature 'Image, missing':
       frameDist(x, y, r, g, b, blur=TRUE, 
           method="dist", verbose, ...)

_A_r_g_u_m_e_n_t_s:

     x,y: A image stacks. 

   r,b,g: If 'x' and 'y' are in TrueColor mode, these values specify
          weights of red, green and blue channels in the resulting
          distance. 

    blur: A logical indicating whether frames ought to be blurred
          before comparison ('TRUE' recommended). 

  method: Method to use: 'dist' - Euclidian distance, 'dot' - dot
          product. 

 verbose: Provides additional output as the function can be lengthy. 

     ...: Reserved. 

_D_e_t_a_i_l_s:

     For Grayscale images, the distance of each pair of frames, 'xf'
     and  'yf', is calculated as 'mean(abs(xf-yf))', where 'mean' is 
     taken over the pixels with at least 'xf' or 'yf' being non-zero. 
     For TrueColor images, the distance is calculated as 
     'mean(sqrt(r*rc^2+g*gc^2+b*bc^2))', where 'rc,gc,bc' are '[0,1]'
     ranged values of red, green and blue channels and 'r,g,b' are the
     weights. Again, the mean is taken only over non-zero pixels.

_V_a_l_u_e:

     A matrix of distances. If 'y' is missing - a square symmetric
     matrix for the distances between frames in the same image with
     diagonal elements set at 'Inf'.

_A_u_t_h_o_r(_s):

     Oleg Sklyar, osklyar@ebi.ac.uk, 2007

_S_e_e _A_l_s_o:

     ' stackObjects '

