PHP Classes

PHP Check Similarity of People Names: Get a similarity score between two people names

Recommend this page to a friend!
  Info   View files Documentation   View files View files (6)   DownloadInstall with Composer Download .zip   Reputation   Support forum   Blog    
Last Updated Ratings Unique User Downloads Download Rankings
2023-12-23 (5 months ago) RSS 2.0 feedNot enough user ratingsTotal: 52 All time: 10,642 This week: 673Up
Version License PHP version Categories
php-similarity-check 1.0MIT/X Consortium ...7Algorithms, User Management, Text pro..., V..., P...
Description 

Authors

Ujah Chigozie
Nanoblock Technology


Contributor

This package can get a similarity score between two people's names.

It can take two strings and check if they are the names of people.

The package can also use the Levenshtein algorithm to calculate a score that determines how similar the people's names are.

Innovation Award
PHP Programming Innovation award nominee
December 2023
Number 7
Some applications let users find other people by name. Sometimes, users do not remember the exact names of the people they want to find.

This package provides a means to compare two people's names using an algorithm derived from the Levenshtein algorithm.

This way, this package can find names that are not the same as the users entered but may be the correct names of the people they want to find.

Manuel Lemos
Picture of Ujah Chigozie peter
  Performance   Level  
Name: Ujah Chigozie peter <contact>
Classes: 25 packages by
Country: Nigeria Nigeria
Innovation award
Innovation award
Nominee: 11x

Documentation

PHP Similarity Checker

PHP class to check the similarity between two items

Functions

  • Calculates the similarity between two persons name

Installation Guide via Composer:

composer require nanoblocktech/php-similarity-check

Usages

Initalize class

use Luminova\ExtraUtils\SimilarityChecker\Check;

Check similarity score between two names

$check = new Check();
try {
    $score = $check->name('Peter Foo', 'Paul Foo'); 

    echo "Percentage: {$score->getRate()}%\n";
    echo "Ratio: {$distance->getRatio()}\n";
} catch (InvalidArgumentException $e){
    echo $e->getMessage();
}

Check similarity score between two string

$score = Check::compare('Foo', 'Faa'); 

echo "Percentage: {$score->getRate()}%\n";
echo "Ratio: {$distance->getRatio()}\n";

  Files folder image Files  
File Role Description
Files folder imagesrc (3 files)
Accessible without login Plain text file composer.json Data Auxiliary data
Accessible without login Plain text file LICENSE Lic. License text
Accessible without login Plain text file README.md Doc. Documentation

  Files folder image Files  /  src  
File Role Description
  Plain text file Check.php Class Class source
  Plain text file Score.php Class Class source
  Plain text file Validation.php Class Class source

 Version Control Unique User Downloads Download Rankings  
 100%
Total:52
This week:0
All time:10,642
This week:673Up