arikurniawans / SimpleCosineSimilarityPHP

Simple cosine similarity implementation in PHP

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Simple cosine similarity implementation in PHP

Cosine similarity is a widely used similarity measure of two texts. This simple code computes cosine similarity of two text files given as parameters. To use this, php-cli (PHP command line interpreter) must be working. The output is written to the STDOUT. I have made the cosine similarity code work in PHP. I have not implemented all of the code. The code is developed using the ideas and piece of codes in various web sites.

Usage:

php computeCosine.php file1 file2

License

This code belongs to public. You can utilize it any way you like.

About

Simple cosine similarity implementation in PHP


Languages

Language:PHP 100.0%