Add length match check for cosine
Merge pull request #7 from JuliaStats/jmw/list

Add length match check for cosine