I was wondering, which focal length I use most. I’m asking this question because I’m considering adding a more compact camera to my equipment, which I can carry with me all the time. One aspect is size, another is image quality (which should be somehow sufficient) and another one is the lens. Assuming I’d take the Panasonic Lumix DMC-GF1, it would be small enough only with the 20mm f/1.7 pencake lens. This lens is 40mm in terms of 35mm film equivalent. A new camera with only one focal length is a bit risky investment. So the 40mm should more or less fit my photography habits. A short analysis of my photos brought up these statistics:
The diagram shows statistics of all my photos taken with my Nikon D70s. As I’m using zoom lenses and fixed lenses, I clustered the photos by focal length and used the “classic” focal lengths, all transformed in 35 mm equivalent focal lengths, as cluster criteria: 24mm, 28mm, 35mm, 50mm, 85mm, 105mm, 140mm, 200mm (and more).
To my surprise, it shows most photos have been taken at around 85mm, followed by 24mm and 50mm.
Gathering metatdata from photos
Some may wonder how these statistics got produced. In fact, it was a very simple programming exercise. Thanks to Fabrizio Giudici’s jrawio Java library, I was able to implement a simple Java program that extracts the metadata from my NEF (Nikon RAW Format) image files. The program is quick and dirty:
public class RawStatMain {
public static void main(final String[] args) throws IOException {
final PrintWriter out = new PrintWriter(new File(args[1]));
new DirectoryWalker() {
protected void handleFile(File file, int depth, Collection results) throws IOException {
if (file.getName().toUpperCase().endsWith(".NEF")) {
ImageReader reader = (ImageReader) ImageIO.getImageReaders(file).next();
reader.setInput(ImageIO.createImageInputStream(file));
IIOMetadata metadata = reader.getImageMetadata(0);
NEFMetadata nefMetadata = (NEFMetadata) metadata;
IFD exifIFD = nefMetadata.getExifIFD();
TagRational focalLength = exifIFD.getFocalLength();
out.println(focalLength.doubleValue());
}
}
public void start() throws IOException {
super.walk(new File(args[0]), new ArrayList());
}
}.start();
out.flush();
out.close();
}
}
Besides the jrawio lib I also used Apache Jakarta commons-io for iterating through the directories. The program simply writes the focal lengths to a file, line by line. Afterwards I imported the file in Open Office Calc for further analysis.

Do you mind if I copy the code sketch to the jrawio blog and link yo this post :-) ? I’m trying to blog about sample code and this is really cool.
Back to the topic, today I was in a store (for other reasons) and I was intrigued by these small sized cameras. Sometimes I travel for business all of a sudden and for a few days, and I can’t carry all my weapons with me. But – have you looked at the smallest Nikons? D60 and D80 (can’t remember which I saw today). The other problem is that the smaller cameras with high crop factor are a problem if you like wide angles like me. The 7-14mm for the Lumix costs about 900 euros (the same as my 12-24mm for the Nikon DX format), which is not cheap…
So now for me the doubt is whether to shift my D200 to secondary and take a D300s+ (I’m not satisfied with the D300s, so I’m waiting for possible news at PhotoKina), or to keep the D200 as primary and replace the old D100 with a “small” Nikon.