An apparatus for processing an image in a portable terminal, the apparatus comprising: a camera unit including an image sensor and lens; a display unit; and a control unit configured to: perform a focusing function based on a plurality of first images that were photographed with varying focus characteristics of an identical subject; obtain the plurality of first images having different focus characteristics by varying a distance between the image sensor and lens while generating an image using the camera unit; divide each of the plurality of first images into a predetermined plurality of areas; calculate an edge value of each area for each of the plurality of first images, wherein the edge value means the average sharpness of each area; obtain a lens position focusing on each area based on the calculated edge value of each area; select a plurality of second images from the plurality of first images based on the number of areas focused by the lens for each position and a predetermined factor of importance; obtain a third image based on the plurality of second images; and cause the display unit to display the obtained third image, wherein the predetermined factor of importance comprises a distance from the center of an image, a type of subject, and an extent of color change. a camera unit including an image sensor and lens; a display unit; and a control unit configured to: perform a focusing function based on a plurality of first images that were photographed with varying focus characteristics of an identical subject; obtain the plurality of first images having different focus characteristics by varying a distance between the image sensor and lens while generating an image using the camera unit; divide each of the plurality of first images into a predetermined plurality of areas; calculate an edge value of each area for each of the plurality of first images, wherein the edge value means the average sharpness of each area; obtain a lens position focusing on each area based on the calculated edge value of each area; select a plurality of second images from the plurality of first images based on the number of areas focused by the lens for each position and a predetermined factor of importance; obtain a third image based on the plurality of second images; and cause the display unit to display the obtained third image, perform a focusing function based on a plurality of first images that were photographed with varying focus characteristics of an identical subject; obtain the plurality of first images having different focus characteristics by varying a distance between the image sensor and lens while generating an image using the camera unit; divide each of the plurality of first images into a predetermined plurality of areas; calculate an edge value of each area for each of the plurality of first images, wherein the edge value means the average sharpness of each area; obtain a lens position focusing on each area based on the calculated edge value of each area; select a plurality of second images from the plurality of first images based on the number of areas focused by the lens for each position and a predetermined factor of importance; obtain a third image based on the plurality of second images; and cause the display unit to display the obtained third image,