SlideShare une entreprise Scribd logo
1  sur  26
C
WEKA
ฉัฐวีณ์ เหลืองมโนธรรม 54102011144
CP 463: Artificial Intelligence
1
การเก็บข้อมูล
2
การเก็บข้อมูล(ต่อ)
จากข้อมูลในสไลด์ที่แล้ว คือ ดังนี้
•แต่ละcolumn จะเป็นชื่อสินค้าที่ซื้อในแต่ละใบเสร็จ
•N=No
•Y=Yes
• Column brand คือ สาขาที่ซื้อสินค้า
• Column name คือ ชื่อของผู้ซื้อ
3
การเก็บข้อมูล(ต่อ)
• Column gender คือ เพศ
• Column weight คือ น้าหนัก
• Column sportsman คือ นักกีฬา
• Column glass คือ ใส่แว่น
4
ขั้นตอนการทางาน
โหลดข้อมูลเข้า
มา โดย
open file
ชื่อ file
as.csv และ
asd.csv
5
ขั้นตอนการทางาน(ต่อ)
เปลี่ยนไฟล์
.csv เป็น
.arff
6
Cluster
SimpleKMean
7
Cluster(ต่อ) numClusters = 2
numClusters =
2
8
Cluster(ต่อ) numClusters = 2
• Number of iterations: 4
• Within cluster sum of squared errors: 94.0
• Initial starting points (random):
• Cluster 0: Y,Y,Y,Y,Y,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N
• ,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,ram142,aye,female,
• thin,TRUE,-0.034483,TRUE,FALSE
• Cluster 1: N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N,N
• ,N,N,N,N,N,N,N,N,N,N,Y,Y,N,N,N,N,N,ram142,aye,female,
• thin,TRUE,-0.03
• Clustered Instances
• 0 13 ( 48%)
• 1 14 ( 52%)4483,TRUE,FALSE
9
10
0
10
20
30
40
50
60
70
80
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
Knee Curve
Cluster(ต่อ)
11
Cluster0 coke
chederw
ord bueger egg lm F
Cluster1
sandwic
h milk F บ่าย มหาลัย
Cluster2 water M
Cluster3 water
saucesa
ge lay M
Cluster4 F
Cluster5 burger water
saucesa
ge
chickenri
ce friedrice
larbmoor
ice salmon F เช้าวันอาทิตย์ บ้าน
Cluster6 oishi voice F
Cluster7 water F เที่ยง มหาลัย,บ้าน
Cluster8 100plus F
Cluster9 water larbmoorice F เที่ยง มหาลัย
Cluster10 water shawape pureriku ice M
Cluster11 gulp lay yogurt lipton nori M
Cluster12 shawape M
Classify
•แก้ไขไฟล์ก่อน โดยการลบข้อมูลใน column ที่เราต้องการจะให้ทานาย ใน
ไฟล์ csv
•แก้ไฟล์จาก csv เป็น arff
•หลังจากนั้นนา attribute ของไฟล์หลัก(.arff)มาใส่ในไฟล์ deploy
(.arff)
12
Classify(ต่อ)
หลังจากนั้นโหลดไฟล์หลัก .arff
เข้ามา เพื่อจะทาการ save
model ที่จะใช้ในการ classify
ข้อมูล ไปที่
tab classify >
functions >
MulyilayerPerceptron
13
Classify(ต่อ)
กด Start
14
Classify(ต่อ)
ทาการ Save model
15
Classify(ต่อ)
ทาการ Load model ที่
Save ไว้ก่อนหน้านี้
16
Classify(ต่อ)
Load model ชื่อ as1.model
17
ใส่แว่นไหม
Test Option
>Supplied test set >กด Set…
18
ใส่แว่นไหม(ต่อ)
เลือกไฟล์ที่จะ
deploy โดยคาถาม
คือใส่แว่นไหม >
Close
19
ใส่แว่นไหม(ต่อ)
หลังจากนั้น คลิกขวาที่
model และกด
Re-evaluate
model on
current test
set
20
ใส่แว่นไหม(ต่อ)
หลังจากนั้น คลิกขวาที่
model อีกที และ
กด Visualize
classifier
errors > save
ข้อมูล
21
ใส่แว่นไหม(ต่อ)
เพื่อที่จะ View
ข้อมูลให้ไปที่ Tools
> ArffViewer
> Open > เลือก
ไฟล์ที่save และทา
การเปิด
22
ใส่แว่นไหม(ต่อ)
นี้คือข้อมูลที่ทานาย
ออกมา
23
เป็ นนักกีฬาไหม
•ขั้นตอนการจักเตรียมข้อมูล และวิธีการดาเนินงานเหมือนกับข้อที่แล้ว ดังนั้นข้อ
นี้จะแสดงแค่ผลลัพธ์ที่ทานายได้
นี้คือข้อมูลที่ทานาย
ออกมา 24
เป็ นเพศไหน
•ขั้นตอนการจักเตรียมข้อมูล และวิธีการดาเนินงานเหมือนกับข้อที่แล้ว ดังนั้นข้อ
นี้จะแสดงแค่ผลลัพธ์ที่ทานายได้
นี้คือข้อมูลที่ทานาย
ออกมา 25
Associate Apriori
Open file ที่จะใช้ และทาการเลือก tab ที่เป็น associate หลังจากนั้น
กดคาว่า Apriori กาหนด Rule = 10
lowerBoundMinSupport = 0.05 minMetric = 0.1
26

Contenu connexe

En vedette

How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
ThinkNow
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
Kurio // The Social Media Age(ncy)
 

En vedette (20)

2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot2024 State of Marketing Report – by Hubspot
2024 State of Marketing Report – by Hubspot
 
Everything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPTEverything You Need To Know About ChatGPT
Everything You Need To Know About ChatGPT
 
Product Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage EngineeringsProduct Design Trends in 2024 | Teenage Engineerings
Product Design Trends in 2024 | Teenage Engineerings
 
How Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental HealthHow Race, Age and Gender Shape Attitudes Towards Mental Health
How Race, Age and Gender Shape Attitudes Towards Mental Health
 
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdfAI Trends in Creative Operations 2024 by Artwork Flow.pdf
AI Trends in Creative Operations 2024 by Artwork Flow.pdf
 
Skeleton Culture Code
Skeleton Culture CodeSkeleton Culture Code
Skeleton Culture Code
 
PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024PEPSICO Presentation to CAGNY Conference Feb 2024
PEPSICO Presentation to CAGNY Conference Feb 2024
 
Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)Content Methodology: A Best Practices Report (Webinar)
Content Methodology: A Best Practices Report (Webinar)
 
How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024How to Prepare For a Successful Job Search for 2024
How to Prepare For a Successful Job Search for 2024
 
Social Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie InsightsSocial Media Marketing Trends 2024 // The Global Indie Insights
Social Media Marketing Trends 2024 // The Global Indie Insights
 
Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024Trends In Paid Search: Navigating The Digital Landscape In 2024
Trends In Paid Search: Navigating The Digital Landscape In 2024
 
5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary5 Public speaking tips from TED - Visualized summary
5 Public speaking tips from TED - Visualized summary
 
ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd ChatGPT and the Future of Work - Clark Boyd
ChatGPT and the Future of Work - Clark Boyd
 
Getting into the tech field. what next
Getting into the tech field. what next Getting into the tech field. what next
Getting into the tech field. what next
 
Google's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search IntentGoogle's Just Not That Into You: Understanding Core Updates & Search Intent
Google's Just Not That Into You: Understanding Core Updates & Search Intent
 
How to have difficult conversations
How to have difficult conversations How to have difficult conversations
How to have difficult conversations
 
Introduction to Data Science
Introduction to Data ScienceIntroduction to Data Science
Introduction to Data Science
 
Time Management & Productivity - Best Practices
Time Management & Productivity -  Best PracticesTime Management & Productivity -  Best Practices
Time Management & Productivity - Best Practices
 
The six step guide to practical project management
The six step guide to practical project managementThe six step guide to practical project management
The six step guide to practical project management
 
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
Beginners Guide to TikTok for Search - Rachel Pearson - We are Tilt __ Bright...
 

54102011144 chathawee luangmanotham weka