1. A measurement apparatus comprising: an imaging unit that images a subject to generate an image data; a display unit that displays an image based on the image data; a region-setting unit that sets, in the image, a predetermined region in the image or a region based on a reference point designated by a user as an extraction region from which an edge of the subject is extracted; an edge extraction unit that extracts the edge of the subject based on an image of the extraction region; a display control unit that causes a graphic indicating the extracted edge to be displayed on the display unit together with the image; an edge selection unit that selects a reference edge from among a plurality of extracted edges based on an instruction from the user when the plurality of edges are extracted; a three-dimensional coordinate calculation unit that calculates three-dimensional coordinates corresponding to points in the image; a reference line calculation unit that calculates a reference line on a space based on the three-dimensional coordinates corresponding to a plurality of points constituting the reference edge; a measurement point designation unit that designates a measurement point in the image; and a distance calculation unit that calculates a distance between the three-dimensional coordinate corresponding to the measurement point and the reference line.