Suppose you are rating apples for quality, to ensure the restaurants you serve get the highest quality apples. The ratings are {1,2,3}, where 1 means bad, 2 is ok and 3 is excellent. But, you want to err on the side of giving lower ratings: you prefer to label an apple as bad if you are not sure, to avoid your customers being dissatisfied with the apples. Better to be cautious, and miss some good apples, than to sell low quality apples. You decide to encode this into the cost function. Your cost is as follows lâŷ – yl ŷ Y cost (ŷ, y) = (1) This cost is twice as high when your prediction for quality ŷ is greater than the actual quality y. The cost is zero when ŷ = y. To make your predictions, you get access to a vector of attributes (features) x describing the apple. Assume you have access to the true distribution p(y|x). You want to reason about (a) the optimal predictor, for each x. Assume you are given a feature vector x. Define c(ŷ) = E[cost(ŷ, Y)|X = x] %3D Let pi = p(y= 1|x), p2 = p(y = 2|x) and p3 = p(y = 3|x). Write down c(ŷ) for each ŷ E {1,2, 3}, in terms of pi: P2: P3:
Suppose you are rating apples for quality, to ensure the restaurants you serve get the highest quality apples. The ratings are {1,2,3}, where 1 means bad, 2 is ok and 3 is excellent. But, you want to err on the side of giving lower ratings: you prefer to label an apple as bad if you are not sure, to avoid your customers being dissatisfied with the apples. Better to be cautious, and miss some good apples, than to sell low quality apples. You decide to encode this into the cost function. Your cost is as follows lâŷ – yl ŷ Y cost (ŷ, y) = (1) This cost is twice as high when your prediction for quality ŷ is greater than the actual quality y. The cost is zero when ŷ = y. To make your predictions, you get access to a vector of attributes (features) x describing the apple. Assume you have access to the true distribution p(y|x). You want to reason about (a) the optimal predictor, for each x. Assume you are given a feature vector x. Define c(ŷ) = E[cost(ŷ, Y)|X = x] %3D Let pi = p(y= 1|x), p2 = p(y = 2|x) and p3 = p(y = 3|x). Write down c(ŷ) for each ŷ E {1,2, 3}, in terms of pi: P2: P3:
Glencoe Algebra 1, Student Edition, 9780079039897, 0079039898, 2018
18th Edition
ISBN:9780079039897
Author:Carter
Publisher:Carter
Chapter10: Statistics
Section10.6: Summarizing Categorical Data
Problem 28PPS
Related questions
Question
100%
Expert Solution
This question has been solved!
Explore an expertly crafted, step-by-step solution for a thorough understanding of key concepts.
Step by step
Solved in 8 steps
Recommended textbooks for you
Glencoe Algebra 1, Student Edition, 9780079039897…
Algebra
ISBN:
9780079039897
Author:
Carter
Publisher:
McGraw Hill
Big Ideas Math A Bridge To Success Algebra 1: Stu…
Algebra
ISBN:
9781680331141
Author:
HOUGHTON MIFFLIN HARCOURT
Publisher:
Houghton Mifflin Harcourt
Glencoe Algebra 1, Student Edition, 9780079039897…
Algebra
ISBN:
9780079039897
Author:
Carter
Publisher:
McGraw Hill
Big Ideas Math A Bridge To Success Algebra 1: Stu…
Algebra
ISBN:
9781680331141
Author:
HOUGHTON MIFFLIN HARCOURT
Publisher:
Houghton Mifflin Harcourt