Added functionality described in issue #8 and the corresponding tests.
.gitignore failed to configure correctly and hindered the correct upload of the files
Merge pull request #10 from Zillolo/metric

Added correct files to metric branch