Algorithm for most commonly used items

时间:2019-04-16 23:10:56

标签: algorithm data-mining recommendation-engine

I'm working on a site which allows contractors to upload blueprints and place various assemblies on it for estimating purposes. I'd like to use an algorithm so that if they place an assembly on a blueprint, and click on the assembly, they can see other assemblies that are most commonly used with that one (e.g. if they place a breaker box it could show that 50' of electrical wire is commonly also used) based using data from all the blueprints currently saved in the system.

Based on the research I've done, it appears that affinity analysis would be the best way to determine which other assemblies are most commonly used with each assembly. I was wondering if anyone can provide any feedback if this would be the best algorithm to use or if there is a better one. All the blueprint/assembly data is stored in an MS SQL database and the backend of the website is written in C# with the data provided to the site via a REST service.

Any information or suggestions would be greatly appreciated.

Thank you in advance.

1 个答案:

答案 0 :(得分:0)

“计数”

正如您所描述的,该问题不需要任何特定的算法。这是一个简单的计数操作,可以由使用GROUP_BYWHEREif (environment.production) { enableProdMode(); } 的任何体面的数据库执行。