{"id":6302,"date":"2025-06-01T14:10:06","date_gmt":"2025-06-04T06:56:06","guid":{"rendered":"https:\/\/badgameshow.com\/steven\/?p=6302"},"modified":"2025-06-04T14:10:06","modified_gmt":"2025-06-04T06:56:06","slug":"%e6%8e%8c%e6%8f%a1%e6%a8%a1%e6%93%ac%e5%99%aa%e9%9f%b3%e6%8c%87%e6%a8%99%e5%b8%b6annobands%e4%ba%a4%e6%98%93%e6%8c%87%e6%a8%99%e7%9a%84%e4%bd%bf%e7%94%a8%e6%99%82%e6%a9%9f%e5%8f%8apython%e7%af%84","status":"publish","type":"post","link":"https:\/\/badgameshow.com\/steven\/python\/%e6%8e%8c%e6%8f%a1%e6%a8%a1%e6%93%ac%e5%99%aa%e9%9f%b3%e6%8c%87%e6%a8%99%e5%b8%b6annobands%e4%ba%a4%e6%98%93%e6%8c%87%e6%a8%99%e7%9a%84%e4%bd%bf%e7%94%a8%e6%99%82%e6%a9%9f%e5%8f%8apython%e7%af%84\/","title":{"rendered":"\u638c\u63e1 ANNO Bands \u4ea4\u6613\u6307\u6a19\uff1a\u4f7f\u7528\u6642\u6a5f\u8207 Python \u5be6\u4f5c\u7bc4\u4f8b\uff082025 \u6700\u65b0\u7248\uff09"},"content":{"rendered":"<p><meta name=\"keywords\" content=\"Python, ANNO Bands, \u4ea4\u6613\u6307\u6a19, \u4f7f\u7528\u6642\u6a5f, \u80a1\u7968\u5e02\u5834\u5206\u6790\"><\/p>\n<h1>ANNO Bands \u4ea4\u6613\u6307\u6a19\u7684\u4f7f\u7528\u6642\u6a5f\u53ca Python \u5be6\u4f5c\u7bc4\u4f8b<\/h1>\n<p>\u6a21\u64ec\u566a\u97f3\u6307\u6a19\u5e36\uff08ANNO Bands\uff09\u662f\u4e00\u7a2e\u5728\u80a1\u7968\u4ea4\u6613\u4e2d\u5ee3\u6cdb\u4f7f\u7528\u7684\u6280\u8853\u6307\u6a19\u3002\u5b83\u80fd\u5920\u5e6b\u52a9\u6295\u8cc7\u8005\u66f4\u6e96\u78ba\u5730\u5206\u6790\u5e02\u5834\u8da8\u52e2\uff0c\u5f9e\u800c\u63d0\u9ad8\u4ea4\u6613\u6c7a\u7b56\u7684\u6709\u6548\u6027\u3002\u672c\u6587\u5c07\u6df1\u5165\u63a2\u8a0e ANNO Bands \u7684\u6700\u4f73\u4f7f\u7528\u6642\u6a5f\uff0c\u4e26\u63d0\u4f9b 2025 \u6700\u65b0\u7684 Python \u5be6\u4f5c\u7bc4\u4f8b\uff0c\u5e6b\u52a9\u60a8\u66f4\u597d\u5730\u61c9\u7528\u9019\u4e00\u6307\u6a19\u3002<\/p>\n<h2>ANNO Bands \u7684\u4f7f\u7528\u6642\u6a5f<\/h2>\n<p>ANNO Bands \u7684\u4e3b\u8981\u529f\u80fd\u662f\u6a21\u64ec\u5e02\u5834\u4e2d\u7684\u566a\u97f3\uff0c\u5e6b\u52a9\u6295\u8cc7\u8005\u5206\u6790\u80a1\u7968\u8d70\u52e2\u3002\u4ee5\u4e0b\u662f\u5e7e\u500b\u95dc\u9375\u7684\u4f7f\u7528\u6642\u6a5f\uff1a<\/p>\n<ul>\n<li>**\u5e02\u5834\u6ce2\u52d5\u8f03\u5927\u6642**\uff1a\u5728\u9ad8\u6ce2\u52d5\u7684\u5e02\u5834\u4e2d\uff0cANNO Bands \u80fd\u5920\u5e6b\u52a9\u6295\u8cc7\u8005\u8b58\u5225\u8da8\u52e2\u8f49\u6298\u9ede\uff0c\u63d0\u9ad8\u4ea4\u6613\u7684\u6e96\u78ba\u6027\u3002<\/li>\n<li>**\u5e02\u5834\u6ce2\u52d5\u8f03\u5c0f\u6642**\uff1a\u5373\u4f7f\u5728\u4f4e\u6ce2\u52d5\u5e02\u5834\uff0cANNO Bands \u4e5f\u80fd\u63d0\u4f9b\u6e05\u6670\u7684\u50f9\u683c\u7bc4\u570d\uff0c\u5e6b\u52a9\u6295\u8cc7\u8005\u628a\u63e1\u6700\u4f73\u9032\u5834\u548c\u51fa\u5834\u6642\u6a5f\u3002<\/li>\n<li>**\u660e\u986f\u8da8\u52e2\u51fa\u73fe\u6642**\uff1aANNO Bands \u53ef\u4ee5\u5e6b\u52a9\u78ba\u8a8d\u5f37\u70c8\u7684\u50f9\u683c\u8da8\u52e2\uff0c\u8b93\u6295\u8cc7\u8005\u5728\u6b63\u78ba\u7684\u6642\u6a5f\u9032\u884c\u8ddf\u96a8\u4ea4\u6613\u3002<\/li>\n<\/ul>\n<h2>\u4f7f\u7528 Python \u5be6\u73fe ANNO Bands<\/h2>\n<p>\u5728 Python \u4e2d\u5be6\u73fe ANNO Bands \u975e\u5e38\u7c21\u55ae\u3002\u60a8\u53ea\u9700\u4f7f\u7528 [anno-bands](https:\/\/pypi.org\/project\/anno-bands\/) \u9019\u500b\u5eab\u5373\u53ef\u3002\u4ee5\u4e0b\u662f 2025 \u6700\u65b0\u8a9e\u6cd5\u7684\u5be6\u4f5c\u7bc4\u4f8b\uff1a<\/p>\n<p>&#8220;`python<br \/>\nimport pandas as pd<br \/>\nimport anno_bands<\/p>\n<p># \u5047\u8a2d\u60a8\u6709\u4e00\u500b\u5305\u542b\u80a1\u7968\u6578\u64da\u7684 DataFrame<br \/>\ndata = pd.DataFrame({<br \/>\n    &#8216;date&#8217;: [&#8216;2025-06-01&#8217;, &#8216;2025-06-02&#8217;, &#8216;2025-06-03&#8217;],<br \/>\n    &#8216;close&#8217;: [100, 102, 101]\n})<\/p>\n<p># \u5275\u5efa ANNO Bands \u5c0d\u8c61<br \/>\nanno_bands_calculator = anno_bands.AnnoBands()<\/p>\n<p># \u8a08\u7b97 ANNO Bands<br \/>\nanno_bands_calculator.calculate(data[&#8216;close&#8217;])<\/p>\n<p># \u7372\u53d6 ANNO Bands \u6578\u64da<br \/>\nanno_bands_data = anno_bands_calculator.get_bands()<\/p>\n<p># \u8f38\u51fa\u7d50\u679c<br \/>\nprint(anno_bands_data)<br \/>\n&#8220;`<\/p>\n<p>\u5728\u9019\u6bb5\u4ee3\u78bc\u4e2d\uff0c\u6211\u5011\u9996\u5148\u532f\u5165\u5fc5\u8981\u7684\u5eab\uff0c\u7136\u5f8c\u5efa\u7acb\u4e00\u500b\u5305\u542b\u80a1\u7968\u6536\u76e4\u50f9\u683c\u7684 DataFrame\u3002\u63a5\u8457\uff0c\u6211\u5011\u5275\u5efa ANNO Bands \u5c0d\u8c61\uff0c\u8a08\u7b97\u4e26\u7372\u53d6 ANNO Bands \u6578\u64da\uff0c\u6700\u5f8c\u8f38\u51fa\u7d50\u679c\u4ee5\u4f9b\u5206\u6790\u3002<\/p>\n<h2>\u932f\u8aa4\u6392\u9664<\/h2>\n<p>\u5728\u4f7f\u7528 ANNO Bands \u6642\uff0c\u53ef\u80fd\u6703\u9047\u5230\u4e00\u4e9b\u5e38\u898b\u932f\u8aa4\u3002\u4f8b\u5982\uff0c\u5982\u679c\u6578\u64da\u683c\u5f0f\u4e0d\u6b63\u78ba\u6216\u7f3a\u5c11\u5fc5\u8981\u6578\u64da\uff0c\u8a08\u7b97\u53ef\u80fd\u6703\u5931\u6557\u3002\u78ba\u4fdd\u63d0\u4f9b\u7684\u6578\u64da\u662f\u6709\u6548\u7684\uff0c\u4e26\u6aa2\u67e5\u8f38\u5165\u7684 DataFrame \u662f\u5426\u5305\u542b\u6b63\u78ba\u7684\u5217\u540d\u548c\u6578\u64da\u985e\u578b\u3002<\/p>\n<h2>\u5ef6\u4f38\u61c9\u7528<\/h2>\n<p>ANNO Bands \u4e0d\u50c5\u53ef\u4ee5\u7528\u65bc\u80a1\u7968\u5e02\u5834\uff0c\u9084\u53ef\u4ee5\u61c9\u7528\u65bc\u5176\u4ed6\u91d1\u878d\u5e02\u5834\uff0c\u5982\u5916\u532f\u6216\u5546\u54c1\u5e02\u5834\u3002\u6295\u8cc7\u8005\u53ef\u4ee5\u5c07 ANNO Bands \u8207\u5176\u4ed6\u6280\u8853\u6307\u6a19\u7d50\u5408\u4f7f\u7528\uff0c\u5982\u79fb\u52d5\u5e73\u5747\u7dda\u6216\u76f8\u5c0d\u5f37\u5f31\u6307\u6a19\uff08RSI\uff09\uff0c\u4ee5\u66f4\u5168\u9762\u5730\u5206\u6790\u5e02\u5834\u8d70\u52e2\u3002<\/p>\n<p>\u6b64\u5916\uff0c\u60a8\u9084\u53ef\u4ee5\u67e5\u770b\u6211\u5011\u5728 [vocus.cc](https:\/\/vocus.cc) \u4e0a\u7684\u5176\u4ed6 Python \u76f8\u95dc\u6559\u5b78\uff0c\u4ee5\u64f4\u5c55\u60a8\u7684\u77e5\u8b58\u548c\u6280\u80fd\u3002<\/p>\n<h2>\u7d50\u8ad6<\/h2>\n<p>ANNO Bands \u662f\u4e00\u7a2e\u5f37\u5927\u7684\u6280\u8853\u6307\u6a19\uff0c\u80fd\u5920\u5e6b\u52a9\u6295\u8cc7\u8005\u5728\u80a1\u7968\u5e02\u5834\u4e2d\u4f5c\u51fa\u66f4\u660e\u667a\u7684\u4ea4\u6613\u6c7a\u7b56\u3002\u672c\u6587\u4ecb\u7d39\u4e86 ANNO Bands \u7684\u4f7f\u7528\u6642\u6a5f\u53ca\u5176 Python \u5be6\u4f5c\uff0c\u671f\u671b\u5c0d\u60a8\u7684\u6295\u8cc7\u4e4b\u8def\u6709\u6240\u5e6b\u52a9\u3002<\/p>\n<h2>Q&#038;A\uff08\u5e38\u898b\u554f\u984c\u89e3\u7b54\uff09<\/h2>\n<p>**Q1: ANNO Bands \u8207\u5176\u4ed6\u6280\u8853\u6307\u6a19\u76f8\u6bd4\u6709\u4f55\u512a\u52e2\uff1f**<br \/>\nA1: ANNO Bands \u80fd\u5920\u6a21\u64ec\u5e02\u5834\u566a\u97f3\uff0c\u63d0\u4f9b\u66f4\u6e05\u6670\u7684\u8da8\u52e2\u5206\u6790\uff0c\u7279\u5225\u9069\u5408\u5728\u9ad8\u6ce2\u52d5\u6216\u4f4e\u6ce2\u52d5\u74b0\u5883\u4e2d\u4f7f\u7528\u3002<\/p>\n<p>**Q2: \u5982\u4f55\u9078\u64c7 ANNO Bands \u7684\u53c3\u6578\u8a2d\u7f6e\uff1f**<br \/>\nA2: \u53c3\u6578\u8a2d\u7f6e\u61c9\u6839\u64da\u6b77\u53f2\u6578\u64da\u56de\u6e2c\u7d50\u679c\u4f86\u6c7a\u5b9a\uff0c\u6295\u8cc7\u8005\u53ef\u4ee5\u6839\u64da\u81ea\u5df1\u7684\u98a8\u96aa\u627f\u53d7\u80fd\u529b\u548c\u4ea4\u6613\u98a8\u683c\u9032\u884c\u8abf\u6574\u3002<\/p>\n<p>**Q3: ANNO Bands \u662f\u5426\u9069\u7528\u65bc\u6240\u6709\u5e02\u5834\uff1f**<br \/>\nA3: \u96d6\u7136 ANNO Bands \u5728\u80a1\u7968\u5e02\u5834\u4e2d\u6700\u70ba\u5e38\u898b\uff0c\u4f46\u5b83\u540c\u6a23\u53ef\u4ee5\u61c9\u7528\u65bc\u5916\u532f\u53ca\u5176\u4ed6\u91d1\u878d\u5e02\u5834\uff0c\u53ea\u9700\u6839\u64da\u5177\u9ad4\u5e02\u5834\u7279\u6027\u9032\u884c\u76f8\u61c9\u8abf\u6574\u5373\u53ef\u3002<br \/>\n&#8212;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u6587\u7ae0\u6458\u8981\uff1a\u6a21\u64ec\u566a\u97f3\u6307\u6a19\u5e36(ANNOBands)\u662f\u4e00\u7a2e\u91dd\u5c0d\u80a1\u7968\u5e02\u5834\u7684\u4ea4\u6613\u6307\u6a19\uff0c\u53ef\u4ee5\u5e6b\u52a9\u6295\u8cc7\u8005\u66f4\u597d\u5730\u5224\u65b7\u80a1\u7968\u5e02\u5834\u7684\u8d70\u52e2\uff0c\u672c\u6587\u5c07\u4ecb\u7d39ANNOBands\u7684\u4f7f\u7528\u6642\u6a5f\u53caPython\u7bc4\u4f8b\uff0c\u8b93\u6295\u8cc7\u8005\u66f4\u52a0\u4e86\u89e3\u5982\u4f55\u4f7f\u7528\u6b64\u6307\u6a19\u3002<\/p>\n","protected":false},"author":1,"featured_media":2518,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[18,189],"tags":[15,188],"class_list":["post-6302","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-python","category-189","tag-python","tag-188"],"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/badgameshow.com\/steven\/wp-content\/uploads\/2022\/12\/DALL\u00b7E-2022-12-28-14.25.55-\u62f7\u8c9d2.png","jetpack-related-posts":[],"jetpack_shortlink":"https:\/\/wp.me\/pcFK27-1DE","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/posts\/6302","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/comments?post=6302"}],"version-history":[{"count":2,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/posts\/6302\/revisions"}],"predecessor-version":[{"id":12735,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/posts\/6302\/revisions\/12735"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/media\/2518"}],"wp:attachment":[{"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/media?parent=6302"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/categories?post=6302"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/badgameshow.com\/steven\/wp-json\/wp\/v2\/tags?post=6302"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}