Case Based Reasoning And Naive Bayes Implementation In Laptop Purchasing Recommender System
on
p-ISSN: 2301-5373
e-ISSN: 2654-5101
Jurnal Elektronik Ilmu Komputer Udayana
Volume 9 No. 3, February 2021
Case Based Reasoning and Naive Bayes Implementation in Laptop Purchasing Recommender System
I Gusti Ngurah Agung Dharmawangsaa1, I Wayan Suprianaa2
aInformatics Department, Udayana University South Kuta, Badung, Bali, Indonesia 1[email protected] 2[email protected]
Abstract
Purchasing a new laptop will be difficult if we do not know what the ideal laptop specification for our needs. Especially with a wide selection of laptops. From this problem, system that can give a recommendation to choose the right laptop based on purchaser’s specification choice is needed. This research using two method, Case Based Reasoning and Naive Bayes. The concept of Case Based Reasoning is the process of solving new problems based on the solutions of similar past problems, While Naive Bayes assumes that the presence of a particular feature in a class is unrelated to the presence of any other feature. Naive bayes will be implemented in retrive process of case based reasoning. The recommender system utilizing 7 feature, Kecepatan Processor, Kapasitas Ram, Tipe Grafis, Ukuran Layar, Ukuran Harddisk, Kecepatan Layar, and Harga. The percentage of respondents who said the system was successful in providing the right recommendations was 70 percent of the total respondents.
Keywords: Case Based Reasoning, Naive Bayes, recommendation system, Feature, Indexing
Laptop purchasing activities usually get some constraints due to a lack of knowledge to determine a clear description of the laptop. Various brands of laptops with different functionality become more confusing to potential buyers. The availability of customer budget also plays a role in determining which laptop to buy. It is certainly difficult to provide the right recommendations to customers. Laptop recommendations that have been offered before, can be reused based on the similar criteria that customers need. The purpose of this research is to create a laptop purchase recommendation system based on the solution from the previous case. This recommendation system will be built using the Case Based Reasoning method, it will study new cases (user input) and will see the similarities to old cases that are already on the case base.
The Case Based Reasoning (CBR) method is a method that mimics the ability of human reasoning to solve a problem or case. solutions that were once used in resolving a case will be stored as a knowledge base for solving new cases. The Case Based Reasoning (CBR) method has 4 stages namely retrieval, reuse, revise and retain. A solution is performed to solve a new case by looking for the value of proximity or similarity between the old case and the new case [1]. One method for finding closeness between new cases and old cases is Naive Bayes. In studies conducted by [2] a system was used to determine whether a patient could have a Caesaran section or not by using the CBR method and calculate similarity using Naive Bayes, the accuracy of the Caesaran section with the CBR method using Naive Bayes is 79%. A similiar research method using Naive Bayes which was implemented in Case Based Reasoning, for 100 different records to determine the value an applicant’s eligibility for admission nursing school. This research shown 96 data tested are correct, so the system accruracy is 96% [3]. another studies
conducted by [4] using fuzzy method and Case Based Reasoning show that system accuracy rate reached 80 percent on 15 customer based on customer suitability of laptop desired.
A recommendation system is a system that can provide suggestions or recommendations of an item that is useful to the user. Such suggestions or recommendations relate to the decisionmaking process. Items on the recommendation system show users what the system recommends, such as goods or services [5].
Case Base Reasoning is a method used to solve a problem based on solutions from previous cases. Troubleshooting cycle using CBR (Case Base Reasoning) follows 4 stages [6] :
-
a. Retrieve, taking back experiences/solutions from previous cases that bear a resemblance to the problems encountered.
-
b. Reuse, reuse the case by copying and integrating the solution from the retrieved case.
-
c. Revise, adapting the solutions that have been taken to solve new problems.
-
d. Retain, store and maintain new validated solutions on the case base.
The flowchart shown below, representing how case based reasoning implemented in this research
Figure 1. Case Based Reasoning flowchart
Naive Bayes algorithm is an algorithm based on looking for opportunities or probabilities against the possibility of an event occurring. The Bayes method is a statistical approach to induction inference. Naive Bayes will be used to search for similiarity of old cases with new cases called retrive processes. Naïve Bayes theorem has the following common forms [7]:
P(H∖X) = p(X|H)p(h)
(1)
v 1 7 P(X)
Keterangan :
X = Data with unknown classes
H = Data X Hypothesis
P(H|X) = Probability of hypothesis H based on condition X
P(H) = Probability hypothesis H
P(X|H) = Probability X based on that conditions
P(X) = Probability of X
The data in this study is in the form of laptop information sold in tokopedia online store which will be the case base of this research. The case base of laptop are Kecepatan Processor, Kapasitas Ram, Tipe Grafis, Ukuran Harddisk, Kecepatan Layar, Harga which will be the feature of the recommendation system.
This laptop recommendation system research system uses 7 features, namely Kecepatan Processor, Kapasitas Ram, Tipe Grafis, Ukuran Harddisk, Kecepatan Layar, Harga.
-
Table 1. Data Indexing
Fitur
Deskripsi
Index
Kecepatan_Processor
Intel Core I9 (sangat cepat)
4
Intel Core I7 (Cepat)
3
Intel Core I5 (sedang)
2
Intel Core I3 (lambat)
1
Kapasitas_Ram
Sangat Besar (64gb)
4
Besar (32gb)
3
Lumayan (16gb)
2
Minimal (8gb)
1
Tipe_Grafis
Sangat Baik(RTX 2080)
5
Baik (RTX 2060-2070)
4
Sedang (GTX 1660-1665)
3
Kecil (GTX 1060-1080)
2
Sangat Kecil (GT)
1
Ukuran_Layar
Besar (18 inch)
3
Sedang (15-17 inch)
2
Kecil (13-14 inch)
1
Ukuran_Harddisk
Besar (2TB)
2
Kecil (512gb-1TB)
1
Kecepatan_Layar
Sangat Cepat (300hz)
4
Cepat (240hz-300hz)
3
Lumayan (120hz-240hz)
2
Kecil (60hz-120hz)
1
Harga
Sangat Mahal (60juta-120juta)
4
Mahal (30juta-60juta)
3
Sedang (10juta-30juta)
2
Murah (5juta-10juta)
1
Case representation is the first step of problem mapping. Here is a table of case representations containing examples of laptop recommendation cases where the feature refers to the table
Table 2. Laptop Recommendation Case Representation Example
Ca se |
Kecepatan_pr ocessor |
Kapasitas_ Ram |
Tipe_G rafis |
Ukuran_L ayar |
Ukuran_Ha rddisk |
Kecepatan_ layar |
Har ga |
Lapt op |
1 |
4 |
3 |
5 |
2 |
2 |
4 |
4 |
1 |
2 |
3 |
3 |
5 |
2 |
1 |
2 |
3 |
2 |
3 |
2 |
1 |
3 |
2 |
1 |
2 |
2 |
3 |
4 |
3 |
2 |
4 |
2 |
1 |
3 |
3 |
4 |
5 |
3 |
2 |
3 |
2 |
1 |
1 |
2 |
5 |
From the information contained in Table 2, the case representation can be built in the form of flat feature-value as in Table 3.
Table 3. Case representation in flat feature-value
Fitur | |
Kecepatan_processor |
4 |
Kapasitas_Ram |
2 |
Tipe_Grafis |
1 |
Ukuran_Layar |
1 |
Ukuran_Harddisk |
1 |
Kecepatan_Layar |
1 |
Harga |
1 |
Solusi | |
Kode_Laptop |
1 |
]⅛ . . indexing
3 IcodeJndex: int(11)
]{} :. laptop ⅛ IcodeJaptop : int(11) - . ∣=∣ laptop : varchar(100) ''--_. ® deskripsi: varchar(1O0) ι < solusi user 8 kode-solusi: int(11)
Figure 2. database relational |
|
This laptop recommendation system uses 3 tables, namely laptop tables, indexing tables, and solusi_user. The indexing table applies as a case base. The solusi_user having the results of recommendations from users who value the proximity or similarity of the recommendation data to the case base. The laptop table contains information about the laptop such as the name of the laptop and its description. While solution tables are only used as helper tables, there is no need to provide relationships.
3.5 Data Input
Figure 3. Data Input Page
The data inputted by selecting the specifications of the laptop to be used, given a choice of categories that can be understood by the user, then the data in this category will be changed by the system into numerical.
To calculate the similarity between the old case (the case that exists in the case base) and the new case, the naive bayes algorithm is used using equations (1). After the retrieval case process is carried out, there is a similarity between the new case and the old case (the case that is on the case base). These results will be sorted from data that has the highest level of likeness. Naive bayes will look for the highest probability of a possible solution. The solution here is a recommended laptop.
3.7
Reuse
Figure 4. recommendation result
Reuse is reusing the solution from the old case base to resolve the problem of the new case. After getting the highest probability result of the retrive process that has been done, the system will recommend the result as shown above.
3.8 Revise
Figure 5. revise page
On this page, a revision is made, to add a new case base if the recommendation stipulated is not in line with expectations. A revision process is performed, if no match is found between what is expected as a solution to increase the case base.
-
3.9 Retain
The retain process is done when the given solution has been approved, the system will add the new case solution to the case base. To add a variety of solutions that the system may provide.
Figure 6. retain approval
-
3.10 System Testing
System testing involves assessing respondents using this system, whether the results of the recommendations are suitable as desired by the respondent or not and the Black Box test aimed at knowing which elements in the system are running properly. Here are the results of the Black Box testing of this recommendation system :
Table 4. Blackbox Testing Result
No |
Test |
Expected Result |
Test Result |
1 |
Inputing laptop specification data to system |
System will process the data and give the recommendation result |
success |
2 |
Inputing new solution for current case in revise page |
System take the new solution as a pending solution that need to be approve |
success |
3 |
Approve new solution |
System add new solution to case base |
success |
This laptop purchase recommendation system was tested directly by the respondent to find out how effectively this system provides recommendations that are appropriate as the respondent desires. As many as 70 percent of the total respondents said the system managed to provide appropriate recommendations.
Laptop purchase recommendation system is a system designed in such a way for users who want to find the ideal laptop according to the needs. The implementation of the Case Based Reasoning method on the recommendation of purchasing this laptop using the existing old case base to look for the value of its similiaritas against the new case base. The process of searching for a similiarity called retrive is carried out by calculating the highest probability of proximity between the old case and the new case. based on respondents' opinion on the specificity of the recommendations given by the system, as many as 70 percent stated the system of giving has managed to provide the appropriate recommendations. Advice on further research to add features and solutions from an existing case base, with the aim of the system can recommend laptops better.
References
-
[1] N. Amaliah, A. Johar and I. W. Dharmayana, “Implementasi Metode Case Based Reasoning (CBR) Dalam Menentukan Klasifikasi Anak Yang Mengalami Reterdasi Mental” Rekursif, vol. 5, p. 33-42, 2017.
-
[2] I. W. Supriana, K. D. Prebiana, “Metode Penalaran Berbasis Kasus (Case Based Reasoning) Dalam
Penentuan Kelayakan Sekolah Perawatan”, Resistor, vol. 3, no. 1, p. 57-65, 2020.
-
[3] N. W. Wiantari, I. W. Supriana, “Implementation of the CBR (Case Based Reasoning) Method In Cases of Caesarean Section” Jurnal Elektronik Ilmu Komputer Udayana, vol. 8, no. 2, p. 181 -189, 2019.
-
[4] D. A. Ardianty, N. M. Yunus, “Rancang Bangun Sistem Fuzzy untuk Rekomendasi Pemilihan Laptop” Citisee, p. 65-70, 2016.
-
[5] F. Ricci, L. Rokach, B. Shapira, “Recommender Systems”, New York: Springer, 2016.
-
[6] D. P. Utomo, S. D. Nasution, “Sistem Pakar Mendeteksi Kerusakan Toner Dengan Menggunakan Metode Case Based-Reasoning”, vol. 3, no. 5, p. 430-434, 2016.
-
[7] H. Annur, “Klasifikasi Masyarakat Miskin Menggunakan Metode Naive Bayes” Ilkom, vol. 10, p. 160-165, 2018.
This page is intentionally left blank
418
Discussion and feedback