denoise               package:EBImage               R Documentation

_N_o_i_s_e _r_e_m_o_v_a_l, _b_l_u_r_r_i_n_g _a_n_d _s_m_o_o_t_h_i_n_g _o_r _i_m_a_g_e_s

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

     This set of functions allows for the removal of noise, blurring
     and smoothing of images. The functions operate of images in any
     image mode. The functions and the corresponding help descriptions
     are ported from _ImageMagick_, see the reference below.

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

       # Noise removal:
       ## S4 method for signature 'Image':
       denoise(x, r=0, ...)
       ## S4 method for signature 'Image':
       mediansmooth(x, r=2, ...)
       ## S4 method for signature 'Image':
       despeckle(x, ...)

       # Sharpening images:
       ## S4 method for signature 'Image':
       sharpen(x, r=0, s=0.5, ...)
       ## S4 method for signature 'Image':
       umask(x, r=0, s=0.5, amount=5, t=2, ...)

       # Blurring images:
       ## S4 method for signature 'Image':
       blur(x, r=0, s=0.5, ...)
       ## S4 method for signature 'Image':
       gblur(x, r=0, s=0.5, ...)

       # Adding noise to images:
       ## S4 method for signature 'Image':
       noise(x, type="G", ...)

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

       x: An object of 'Image'. 

       r: A numeric value for the radius of the pixel neighbourhood.
          Passing 0 enables automatic radius selection, default. 

       s: A numeric value for the standard deviation of the Laplacian
          ('sharpen') or Gaussian ('umask, blur, gblur'), in pixels.
          For reasonable results, in most functions 'r' must be larger
          than 's'. 

  amount: A numeric value for the percentage difference between the
          original and the blurred image that is added back into the
          original in the un-sharp mask algorithm. 

       t: A numeric value for the threshold in pixels needed to apply
          the 'amount' in the un-sharp mask algorithm.

    type: The type of noise to add. Supported noise types are:
          'Uniform, Gaussian' (default), 'Multi, Impulse, Laplace' and
          'Poisson'. The value can be specified by one letter. Case
          insensitive. 

     ...: Reserved. 

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

     'despeckle' reduces the speckle-type, single-pixel, noise.

     'mediansmooth' smooths the noisy image by replacing each pixel by
     a median of pixel values in taken over the neighbouring as defined
     by radius.

     'blur, gblur' produce a blurred image. The 'blur' method differs
     from the Gaussian blur, 'gblur', in that it uses a separable
     kernel which is faster but mathematically equivalent to the
     non-separable kernel.

     'sharpen, umask' sharpen an image. 'umask' uses the un-sharp mask
     algorithm, in which the image is convolved with a Gaussian
     operator of the given radius and standard deviation, 's'.

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

     A transformed image in an object of 'Image'.

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

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

_R_e_f_e_r_e_n_c_e_s:

     _ImageMagick_: <URL: http://www.imagemagick.org>.

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

     ' Image, normalize '

_E_x_a_m_p_l_e_s:

       w <- 120
       a <- Image((0:(w^2))/w^2, c(w,w))
       if ( interactive() ) display(a)
       b <- normalize(noise(a) * 0.1)
       if ( interactive() ) display(b)
       dn <- despeckle(b)
       if ( interactive() ) display(dn)
       bl <- blur(dn, 4, 2)
       if ( interactive() ) display(bl)

