{"id":903,"date":"2017-02-11T17:14:25","date_gmt":"2017-02-11T09:14:25","guid":{"rendered":"https:\/\/www.beneplot.com\/?p=903"},"modified":"2021-05-28T16:12:41","modified_gmt":"2021-05-28T08:12:41","slug":"%e5%9b%9b%e5%a4%a7%e5%b8%b8%e7%94%a8%e5%88%86%e7%b1%bb%e6%a8%a1%e5%9e%8b-%e6%a8%a1%e5%9e%8b%e5%af%b9%e6%af%94%e4%b8%8e%e8%af%84%e5%88%a4%e6%8c%87%e6%a0%87","status":"publish","type":"post","link":"https:\/\/www.beneplot.com\/?p=903","title":{"rendered":"\u56db\u5927\u5e38\u7528\u5206\u7c7b\u6a21\u578b &#038; \u6a21\u578b\u5bf9\u6bd4\u4e0e\u8bc4\u5224\u6307\u6807"},"content":{"rendered":"<p>&nbsp;<\/p>\n<p><span style=\"font-size: 16px;\"><strong>KNN<\/strong>(K-nearest neighbors)\u3001<strong>logistic\u56de\u5f52<\/strong>\u3001<strong>LDA<\/strong>(Linear discriminant analysis)\u3001<strong>QDA<\/strong>(Quadratic discriminant analysis)\u662f\u56db\u5927\u5e38\u7528\u7684\u5206\u7c7b\u9884\u6d4b\u6a21\u578b\u3002\u5176\u4e2d\u9664<strong>KNN\u662f\u975e\u53c2\u6570\u6a21\u578b<\/strong>\u5916\uff0c\u5176\u4ed6\u4e09\u4e2a\u90fd\u662f\u53c2\u6570\u6a21\u578b\u3002<strong>\u975e\u53c2\u6570(non-parametric)\u6a21\u578b<\/strong>\u6307\u4e0d\u660e\u786e\u5047\u8bbe\u4e00\u4e2a\u6216\u591a\u4e2a\u53c2\u6570\u5316\u5f62\u5f0f<strong>F(x)<\/strong>\u7684\u65b9\u6cd5\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u5f53<strong>Y\u4e3a\u4e24\u7c7b\u6570\u636e<\/strong>\u65f6\uff0clogistic\u56de\u5f52\u548cLDA\u7684\u5206\u7c7b\u9884\u6d4b\u7ed3\u679c\u4f1a\u5f88\u8fd1\u4f3c\u3002<strong>logistic\u56de\u5f52<\/strong>\u4e3b\u8981\u7528\u4e8eY\u662f\u4e24\u7c7b\u6570\u636e\u65f6\u7684\u5206\u7c7b\uff0c\u800c\u5f53<strong>Y\u7684\u6570\u636e\u7c7b\u522b\u8d85\u8fc7\u4e24\u7c7b\u65f6<\/strong>\uff0c<strong>LDA<\/strong>\u88ab\u66f4\u591a\u7684\u4f7f\u7528\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u5f71\u54cdlogistic\u56de\u5f52\u5206\u7c7b\u9884\u6d4b\u51c6\u786e\u7387\u7684\u4e00\u4e2a\u91cd\u8981\u70b9\u662f\uff1a<strong>\u9884\u6d4b\u6982\u7387\u7684\u9608\u503c\u7684\u8bbe\u5b9a\uff01<\/strong>\u5373\u8bbe\u5b9a\u8d85\u8fc7\u67d0\u4e2a\u6982\u7387\u503c\u65f6\u5224\u5b9a\u4e3a\u4e0d\u540c\u7684\u7c7b\u522b\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u5f53<strong>\u5206\u7c7b\u51b3\u7b56\u8fb9\u754c\u662f\u7ebf\u6027<\/strong>\u65f6\uff0clogistic\u56de\u5f52\u548cLDA\u662f\u66f4\u4f73\u7684\u5206\u7c7b\u6a21\u578b\uff0c\u800c\u5f53<strong>\u5206\u7c7b\u51b3\u7b56\u8fb9\u754c\u662f\u975e\u7ebf\u6027<\/strong>\u65f6\uff0c<strong>QDA<\/strong>\u6a21\u578b\u5206\u7c7b\u9884\u6d4b\u51c6\u786e\u6027\u4f1a\u66f4\u4f73\u3002\u987e\u540d\u601d\u4e49\uff0cQDA\u662f\u4e00\u4e2a\u4e8c\u6b21\u51fd\u6570\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u9700\u8981\u6ce8\u610f\u7684\u662f\uff1a<strong>LDA\u548cQDA\u90fd\u662f\u5efa\u7acb\u5728\u6570\u636e\u5448\u6b63\u6001\u5206\u5e03\u7684\u5047\u8bbe\u524d\u63d0\u4e0a<\/strong>\uff0c\u5982\u679c\u6570\u636e\u4e0d\u6ee1\u8db3\u6b63\u6001\u5206\u5e03\uff0c\u5206\u7c7b\u7ed3\u679c\u53ef\u80fd\u4f1a\u5f88\u7cdf\u7cd5\uff0c\u6b64\u65f6\u53ef\u4ee5\u5c1d\u8bd5\u4f7f\u7528<strong>logistic\u56de\u5f52<\/strong>\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\"><strong>\u5f53\u5206\u7c7b\u51b3\u7b56\u8fb9\u754c\u5f88\u590d\u6742\u65f6\uff0c\u975e\u53c2\u6570\u65b9\u6cd5KNN\u7684\u5206\u7c7b\u7ed3\u679c\u66f4\u4f73\u3002<\/strong><\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u5728\u4f7f\u7528KNN\u7b97\u6cd5\u65f6\u9700\u6ce8\u610f\uff1a<strong>KNN\u7684\u539f\u7406\u662f\u901a\u8fc7\u5708\u5b9a\u8ddd\u79bb\u6700\u8fd1\u7684\u89c2\u6d4b\u503c\u6765\u5b9e\u73b0<\/strong>\uff0c\u56e0\u6b64\uff0c\u53d8\u91cf\u7684\u53d6\u503c\u5c3a\u5ea6\u5c06<\/span><span style=\"font-size: 16px;\">\u4f1a<\/span><span style=\"font-size: 16px;\">\u5bf9\u7ed3\u679c\u4ea7\u751f\u5f71\u54cd\u3002\u6240\u4ee5\uff0c<\/span><strong style=\"font-size: 16px;\">\u5728\u5e94\u7528KNN\u65f6\uff0c\u9700\u9996\u5148\u5c06\u6240\u6709\u53d8\u91cf\u7edf\u4e00\u5c3a\u5ea6\uff0c\u4ee5\u4f7f\u5f97\u4e0d\u540c\u53d8\u91cf\u7684\u6570\u636e\u53ef\u4ee5\u76f8\u4e92\u6bd4\u8f83\u3002<\/strong><span style=\"font-size: 16px;\">\u4e00\u4e2a\u65b9\u6cd5\u662f<\/span><strong style=\"font-size: 16px;\">\u6807\u51c6\u5316\u6570\u636e<\/strong><span style=\"font-size: 16px;\">\uff0c\u6bd4\u5982\uff0c\u53ef\u5c06\u6240\u6709\u53d8\u91cf\u8f6c\u5316\u4e3a\u4ee50\u4e3a\u5747\u503c\u30011\u4e3a\u6807\u51c6\u5dee\u7684\u6570\u636e\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u5f71\u54cdKNN\u5206\u7c7b\u9884\u6d4b\u51c6\u786e\u7387\u7684\u4e00\u4e2a\u91cd\u8981\u70b9\u662f\uff1a<strong>K\u503c\u7684\u8bbe\u5b9a\uff01<\/strong><\/span><\/p>\n<p>&nbsp;<\/p>\n<hr \/>\n<p><span style=\"font-size: 16px;\"><strong>\u5206\u7c7b\u51c6\u786e\u7387(accuracy rate of prediction)<\/strong>\u662f<strong>\u5bf9\u6bd4\u4e0d\u540c<\/strong>\u5206\u7c7b\u6a21\u578b\u4f18\u52a3\u7684\u4e00\u4e2a\u6838\u5fc3\u8bc4\u5224\u6307\u6807\uff0c\u800c<strong>\u504f\u5dee(Bias)\u548c\u65b9\u5dee(Variance)<\/strong>\u5219\u662f<strong>\u8bc4\u5224\u6a21\u578b\u672c\u8eab<\/strong>\u6548\u80fd\u4f18\u52a3\u7684\u4e24\u4e2a\u6838\u5fc3\u6307\u6807\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\"><strong>\u504f\u5dee\u6307\u6a21\u578b\u7684\u9884\u6d4b\u7ed3\u679c\u4e0e\u771f\u5b9e\u7ed3\u679c\u4e4b\u95f4\u7684\u5dee\u5f02<\/strong>\u3002\u901a\u4fd7\u7684\u8bf4\uff0c\u504f\u5dee\u88ab\u7528\u4e8e\u8861\u91cf\u5f53\u524d\u4f7f\u7528\u7684\u6a21\u578b\u4e0e\u5f53\u524d\u6570\u636e\u7684\u5339\u914d\u7a0b\u5ea6\uff0c\u4ee5\u53ca\u5bf9\u5f53\u524d\u6570\u636e\u7684\u89e3\u91ca\u7a0b\u5ea6\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\"><strong>\u65b9\u5dee\u6307\u540c\u4e00\u4e2a\u6a21\u578b\u5bf9\u4e0d\u540c\u6279\u6b21\u6570\u636e\u7684\u5206\u6790\u7ed3\u679c\u7684\u5dee\u5f02<\/strong>\u3002\u901a\u4fd7\u7684\u8bf4\uff0c\u65b9\u5dee\u88ab\u7528\u4e8e\u8861\u91cf\u4e00\u4e2a\u6a21\u578b\u8868\u73b0\u7684<strong>\u7a33\u5b9a\u6027\u548c\u53ef\u63a8\u5e7f\u6027<\/strong>\uff0c\u5373\u591a\u6b21\u6a21\u578b\u5206\u6790\u7684\u7ed3\u679c\u662f\u5426\u4e00\u81f4\u548c\u7a33\u5b9a\uff0c\u4ee5\u53ca\u9664\u4e86\u5f53\u524d\u6570\u636e\u5916\uff0c\u6a21\u578b\u662f\u5426\u53ef\u4ee5\u63a8\u5e7f\u5e94\u7528\u5230\u5176\u4ed6\u7c7b\u4f3c\u7684\u6570\u636e\u4e2d\u3002<\/span><\/p>\n<p><img src=\"https:\/\/www.beneplot.com\/?attachment_id=905\" alt=\"\" \/><\/p>\n<p><span style=\"font-size: 16px;\">\u5bf9\u4e8e<strong>\u53c2\u6570\u6a21\u578b<\/strong>\u6765\u8bf4\uff0c\u6a21\u578b\u5305\u542b\u7684\u53c2\u6570\u8d8a\u591a(\u5373\u6a21\u578b\u8d8a<strong>\u590d\u6742<\/strong>)\uff0c\u5b83\u4e0e\u5f53\u524d\u6570\u636e\u7684\u62df\u5408\u4f1a\u8d8a\u597d\uff0c\u590d\u6742\u7684\u6a21\u578b\u80fd\u66f4\u597d\u7684\u89e3\u91ca\u5f53\u524d\u7684\u5efa\u6a21\u6570\u636e\uff0c\u4f7f\u5f97<strong>\u504f\u5dee\u5f88\u4f4e<\/strong>\u3002\u7136\u800c\uff0c\u5f53\u5bf9\u65b0\u6570\u636e\u8fdb\u884c\u5206\u6790\u65f6\uff0c\u5982\u679c\u6a21\u578b\u8fc7\u5ea6\u5339\u914d\u8fc7\u53bb\u7684\u5efa\u6a21\u6570\u636e\uff0c\u5b83\u5bf9\u65b0\u6570\u636e\u7684\u89e3\u91ca\u6216\u9884\u6d4b\u5f88\u53ef\u80fd\u4f1a\u51fa\u73b0\u9519\u8bef\u6216\u504f\u79bb\uff0c\u4ece\u800c\u5bfc\u81f4<strong>\u65b9\u5dee\u589e\u5927<\/strong>\u3002\u8fd9\u79cd\u73b0\u8c61\u88ab\u79f0\u4e3a\uff1a\u6a21\u578b<strong>\u8fc7\u62df\u5408(Overfit)<\/strong>\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u4f46\u662f\uff0c\u5982\u679c\u6a21\u578b\u8fc7\u4e8e<strong>\u7b80\u5355<\/strong>\uff0c\u53c8\u5bb9\u6613\u5bfc\u81f4\u6a21\u578b\u7684<strong>\u6b20\u62df\u5408(Underfit)<\/strong>\uff0c\u6b64\u65f6\uff0c\u504f\u5dee\u4f1a\u663e\u8457\u589e\u52a0\uff0c\u5373\u6a21\u578b\u5bf9\u6570\u636e\u7684\u89e3\u91ca\u529b\u5ea6\u4e0d\u8db3\uff0c\u9884\u6d4b\u6b63\u786e\u7387\u4f4e\u3002\u7136\u800c\uff0c\u7531\u4e8e\u6b20\u62df\u5408\u6a21\u578b\u7684\u8868\u73b0\u5f88\u5e73\u5747\u5316\uff0c\u5b83\u5728\u5206\u6790\u4e0d\u540c\u6570\u636e\u65f6\u7684\u7ed3\u679c\u53ef\u80fd\u4f1a\u6bd4\u8f83\u7a33\u5b9a\uff0c\u5373\u6a21\u578b<strong>\u4f4e\u65b9\u5dee<\/strong>\u3002<\/span><\/p>\n<p><span style=\"font-size: 16px;\">\u56e0\u6b64\uff0c\u5728\u6784\u5efa\u6216\u9009\u62e9\u6a21\u578b\u65f6\uff0c\u5e76\u975e\u504f\u5dee\u8d8a\u4f4e\u8d8a\u597d\uff0c\u540c\u65f6\u4e5f\u9700\u8981\u8003\u8651\u6a21\u578b\u7684\u65b9\u5dee\uff08\u5373<strong>\u53ef\u63a8\u5e7f\u6027\u548c\u666e\u904d\u9002\u7528\u6027<\/strong>\uff09\u3002\u8fd9\u88ab\u79f0\u4e3a\uff1a<strong>\u504f\u5dee\u4e0e\u65b9\u5dee\u6743\u8861(Bias-Variance trade-off)<\/strong>\u3002\u504f\u5dee\u4e0e\u65b9\u5dee\u6743\u8861\u5b9e\u9645\u4e0a\u4e5f\u662f<strong>\u8fc7\u62df\u5408\u4e0e\u6b20\u62df\u5408\u7684\u6743\u8861<\/strong>\uff0c\u4ea6\u662f<strong>\u7b80\u5355\u4e0e\u590d\u6742\u7684\u6743\u8861<\/strong>\uff01<\/span><\/p>\n<p><img src=\"https:\/\/www.beneplot.com\/?attachment_id=906\" alt=\"\" \/><\/p>\n<p><span style=\"font-size: 16px;\">\u5bf9\u4e8e<strong>\u975e\u53c2\u6570\u6a21\u578b<\/strong>\u540c\u6837\u5982\u6b64\uff0cKNN\u5206\u7c7b\u6a21\u578b\u4e2d<strong>K\u503c\u7684\u8bbe\u5b9a<\/strong>\u80fd\u975e\u5e38\u8d34\u5207\u7684\u8bf4\u660e\u4e0a\u8ff0\u7684<strong>\u6743\u8861\u95ee\u9898<\/strong>\u3002<strong>K\u503c\u6700\u5c0f\u53ef\u8bbe\u5b9a\u4e3a1<\/strong>\uff0c\u6b64\u65f6\uff0cKNN\u6a21\u578b\u7684\u51b3\u7b56\u8fb9\u754c\u6700\u4e3a\u590d\u6742\uff0c\u5176\u62df\u5408\u6700\u597d\u3001\u504f\u5dee\u6700\u5c0f\uff0c\u4f46\u8fd9\u975e\u5e38\u5bb9\u6613\u5bfc\u81f4\u6a21\u578b\u7684<strong>\u8fc7\u62df\u5408\u548c\u9ad8\u65b9\u5dee<\/strong>\u3002\u800c<strong>\u968f\u7740K\u503c\u7684\u589e\u52a0\uff0cKNN\u6a21\u578b\u7684\u51b3\u7b56\u8fb9\u754c\u4f1a\u8d8a\u6765\u8d8a\u63a5\u8fd1\u7ebf\u6027<\/strong>\uff0c\u5176\u62df\u5408\u9010\u6e10\u964d\u4f4e\u3001\u504f\u5dee\u9010\u6e10\u589e\u52a0\uff0c\u65b9\u5dee\u4e5f\u4f1a\u9010\u6e10\u964d\u4f4e\u3002\u5f53K\u503c\u589e\u52a0\u5230\u4e00\u5b9a\u9650\u5ea6\u65f6\uff0c\u6a21\u578b\u5c06<strong>\u6b20\u62df\u5408\uff0c<\/strong>\u4ece\u800c\u53d8\u6210\u4e86\u4e00\u4e2a\u4e2d\u5eb8\u4e14\u7528\u5904\u4e0d\u5927\u7684\u6a21\u578b\u3002\u56e0\u6b64\uff0c<strong>\u5bfb\u627e\u6700\u4f73\u7684K\u503c\u5bf9KNN\u6a21\u578b\u81f3\u5173\u91cd\u8981<\/strong>\u3002<\/span><\/p>\n<p>&nbsp;<\/p>\n<p>END<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; KNN(K-nearest neighbors)\u3001logistic\u56de\u5f52\u3001LDA(Linear d [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[1],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v14.3 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<meta name=\"robots\" content=\"index, follow\" \/>\n<meta name=\"googlebot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta name=\"bingbot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.beneplot.com\/?p=903\" \/>\n<meta property=\"og:locale\" content=\"zh_CN\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"\u56db\u5927\u5e38\u7528\u5206\u7c7b\u6a21\u578b &amp; \u6a21\u578b\u5bf9\u6bd4\u4e0e\u8bc4\u5224\u6307\u6807 - Beneplot\" \/>\n<meta property=\"og:description\" content=\"&nbsp; KNN(K-nearest neighbors)\u3001logistic\u56de\u5f52\u3001LDA(Linear d [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.beneplot.com\/?p=903\" \/>\n<meta property=\"og:site_name\" content=\"Beneplot\" \/>\n<meta property=\"article:published_time\" content=\"2017-02-11T09:14:25+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2021-05-28T08:12:41+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.beneplot.com\/?attachment_id=905\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/www.beneplot.com\/#website\",\"url\":\"https:\/\/www.beneplot.com\/\",\"name\":\"Beneplot\",\"description\":\"\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/www.beneplot.com\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"zh-CN\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.beneplot.com\/?p=903#primaryimage\",\"inLanguage\":\"zh-CN\",\"url\":\"https:\/\/www.beneplot.com\/?attachment_id=905\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/www.beneplot.com\/?p=903#webpage\",\"url\":\"https:\/\/www.beneplot.com\/?p=903\",\"name\":\"\\u56db\\u5927\\u5e38\\u7528\\u5206\\u7c7b\\u6a21\\u578b & \\u6a21\\u578b\\u5bf9\\u6bd4\\u4e0e\\u8bc4\\u5224\\u6307\\u6807 - Beneplot\",\"isPartOf\":{\"@id\":\"https:\/\/www.beneplot.com\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/www.beneplot.com\/?p=903#primaryimage\"},\"datePublished\":\"2017-02-11T09:14:25+00:00\",\"dateModified\":\"2021-05-28T08:12:41+00:00\",\"author\":{\"@id\":\"https:\/\/www.beneplot.com\/#\/schema\/person\/ea14f85ae789ceaaa712ceee1dd1f95b\"},\"inLanguage\":\"zh-CN\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/www.beneplot.com\/?p=903\"]}]},{\"@type\":[\"Person\"],\"@id\":\"https:\/\/www.beneplot.com\/#\/schema\/person\/ea14f85ae789ceaaa712ceee1dd1f95b\",\"name\":\"beneplot\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/www.beneplot.com\/#personlogo\",\"inLanguage\":\"zh-CN\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/15d96ce801cfddbd59ef2b0d986cd9b1?s=96&r=g\",\"caption\":\"beneplot\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","_links":{"self":[{"href":"https:\/\/www.beneplot.com\/index.php?rest_route=\/wp\/v2\/posts\/903"}],"collection":[{"href":"https:\/\/www.beneplot.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.beneplot.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.beneplot.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.beneplot.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=903"}],"version-history":[{"count":22,"href":"https:\/\/www.beneplot.com\/index.php?rest_route=\/wp\/v2\/posts\/903\/revisions"}],"predecessor-version":[{"id":913,"href":"https:\/\/www.beneplot.com\/index.php?rest_route=\/wp\/v2\/posts\/903\/revisions\/913"}],"wp:attachment":[{"href":"https:\/\/www.beneplot.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=903"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.beneplot.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=903"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.beneplot.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=903"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}