匹配字符串列表 [英] Match list of string

查看:113
本文介绍了匹配字符串列表的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有来自不同供应商的酒店名称列表。我需要匹配一个供应商的酒店名称,例如一个供应商给出酒店名称,如El Conquistador Resort,Waldorf Astoria Hotel和其他供应商提供的相同酒店像El Conquistador Resort -Waldorf Astoria Collection或Country Inn Suites Olean这样的名字给出了Country Inn&Suites By Carlson,Olean,NY。我需要达到至少90%的准确度。



请帮帮我。谢谢提前..........



更多例子......



盐湖城万怡酒店,盐湖城市中心万怡酒店和

Stamford Plaza Auckland,Stamford Plaza Auckland和

Hampton Inn Houston I45 North,Hampton Inn Houston-The Woodlands和

诺克斯维尔万豪酒店,诺克斯维尔万豪酒店和

Hotel Clarion Quebec,Clarion Hotel Quebec Ste-Foy和

Schlitterbahn Beach Resort and Waterp方舟,Schlitterbahn海滩度假村和水上乐园和

山丘酒店,阿桑德连锁酒店成员,山丘酒店,登高精选酒店

I have list of hotel name with their address from different suppliers.i need to match hotel name from one supplier, for example one supplier gives hotel name like "El Conquistador Resort, a Waldorf Astoria Hotel" and other suppliers provides same hotel name like "El Conquistador Resort -Waldorf Astoria Collection" or "Country Inn Suites Olean"other supplier gives"Country Inn & Suites By Carlson, Olean, NY. i need to achieve at least 90% accuracy.

Please help me .Thanks in advance..........

More Example ...

"Courtyard by Marriott Salt Lake City" ,"Courtyard Salt Lake City Downtown" And
"Stamford Plaza Auckland" , "Stamford Plaza Auckland" And
"Hampton Inn Houston I45 North" , "Hampton Inn Houston-The Woodlands" And
"Marriott Knoxville" , "Knoxville Marriott" And
"Hotel Clarion Quebec","Clarion Hotel Quebec Ste-Foy" And
"Schlitterbahn Beach Resort and Waterpark" , "Schlitterbahn Beach Resort and Water Park"And
"The Hills Hotel, an Ascend Hotel Collection Member","The Hills Hotel, an Ascend Collection hotel"

推荐答案

程序需要找到一种方法来衡量单词之间的相似性,查看 Levenshtein距离算法 [ ^ ]
The program will need to find a way to measure the similarity between words, check out the Levenshtein Distance Algorithm[^]


这篇关于匹配字符串列表的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆