jamescurran / humannameparser Goto Github PK
View Code? Open in Web Editor NEWReturns the parts (leading initial, first, middle, last, suffix) of a name from a string. C#/.NET Port of the original PHP HumanNameParse
License: MIT License
Returns the parts (leading initial, first, middle, last, suffix) of a name from a string. C#/.NET Port of the original PHP HumanNameParse
License: MIT License
Does not properly parse a name formatted as "last,first" with no spaces around the comma. This results in the full name being classified as just the last name. Interestingly, if you add a middle name onto this, it does correctly parse all of the names: "last,first middle".
Simple fix for this is to change the following in the Parse method:
if (name.IndexOf(' ') == -1)
to
if (name.IndexOf(' ') == -1 && name.IndexOf(',') == -1)
This would allow the package to be accessed from modern .NET environments without pulling-in extra .NET Standard 1.6 transitive dependencies.
I have a raw name that is like, TERRENCE H. BORING, M.D.
and parsing this with expectations as below:
Title: ""
FirstName: TERRENCE
Middle: H.
Lastname: BORING
Suffix: M.D.
But the actual Result is,
Title: ""
FirstName: M.D.
Middle: TERRENCE H.
Lastname: BORING
Suffix: ""
This is wrong and my guess is, it detects comma in the given name and assumes as "LastName, FirstName" format. Although, you have some samples in the github, seems its not parsing correctly.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.