Skip to content

Commit 50afefb

Browse files
authored
Update README.md
1 parent 3b234a1 commit 50afefb

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

README.md

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ Recommend a product using collaborative filtering
2424
**/
2525
use Tigo\Recommend; // import class
2626
$client = new Recommend();
27-
$client->ranking($table,$user)
28-
$client->euclidean($table,$user,0);
27+
$client->ranking($table,$user) //optional third parameter refers to the score not accepted
28+
$client->euclidean($table,$user); //optional third parameter refers to the minimum accepted score
2929
```
3030

3131
### Configuration
@@ -71,7 +71,9 @@ A simple didactic demonstration of the algorithm
7171
use Tigo\Recommend; // import class
7272
$client = new Recommend();
7373
print_r($client->ranking($table,"Pedro")); // result = ['C' => 2]
74-
print_r($client->euclidean($table,"Pedro", 0)); // result = ['C' => 1]
74+
print_r($client->ranking($t->get(),"Pedro",1)); // result = [];
75+
76+
print_r($client->euclidean($table,"Pedro")); // result = ['C' => 1]
7577
/**third parameter determines the lowest accepted score**/
7678
print_r($client->euclidean($table,"Pedro", 2)); // result = [] ;
7779
```

0 commit comments

Comments
 (0)