{"id":126,"date":"2025-06-17T07:11:52","date_gmt":"2025-06-17T07:11:52","guid":{"rendered":"https:\/\/blog.alltick.co\/ja-jp\/?p=126"},"modified":"2025-06-17T07:11:53","modified_gmt":"2025-06-17T07:11:53","slug":"mean-reversion-strategy","status":"publish","type":"post","link":"https:\/\/blog.alltick.co\/ja-jp\/mean-reversion-strategy\/","title":{"rendered":"\u5e73\u5747\u56de\u5e30\u6226\u7565"},"content":{"rendered":"\n<p>\u5e73\u5747\u56de\u5e30\u6226\u7565\u306f\u3001\u91cf\u7684\u53d6\u5f15\u306b\u304a\u3051\u308b\u7d71\u8a08\u7684\u30a2\u30fc\u30d3\u30c8\u30e9\u30fc\u30b8\u30a2\u30d7\u30ed\u30fc\u30c1\u306e\u4e00\u7a2e\u3067\u3059\u3002\u3053\u306e\u6226\u7565\u306f\u3001\u8cc7\u7523\u4fa1\u683c\u304c\u77ed\u671f\u7684\u306a\u9038\u8131\u306e\u5f8c\u306b\u9577\u671f\u7684\u306a\u5e73\u5747\u306b\u623b\u308b\u50be\u5411\u304c\u3042\u308b\u3068\u3044\u3046\u8003\u3048\u306b\u57fa\u3065\u3044\u3066\u3044\u307e\u3059\u3002\u57fa\u672c\u7684\u306a\u524d\u63d0\u306f\u3001\u4fa1\u683c\u304c\u6b74\u53f2\u7684\u306a\u5e73\u5747\u304b\u3089\u5927\u304d\u304f\u9038\u8131\u3057\u305f\u5834\u5408\u3001\u6700\u7d42\u7684\u306b\u306f\u305d\u306e\u5e73\u5747\u306b\u623b\u308b\u3068\u3044\u3046\u3082\u306e\u3067\u3059\u3002<\/p>\n\n\n\n<p>\u3053\u306e\u6226\u7565\u306f\u3001\u3055\u307e\u3056\u307e\u306a\u91cf\u7684\u624b\u6cd5\u3092\u63a2\u6c42\u3059\u308b\u66f8\u7c4d\u300e\u7d71\u8a08\u7684\u30a2\u30fc\u30d3\u30c8\u30e9\u30fc\u30b8\u300f\u3067\u8a73\u7d30\u306b\u7d39\u4ecb\u3055\u308c\u3066\u3044\u307e\u3059\u3002\u5e73\u5747\u56de\u5e30\u53d6\u5f15\u3067\u306f\u3001\u30c8\u30ec\u30fc\u30c0\u30fc\u306f\u901a\u5e38\u3001\u5f37\u3044\u76f8\u95a2\u95a2\u4fc2\u3092\u6301\u30641\u7d44\u307e\u305f\u306f\u305d\u308c\u4ee5\u4e0a\u306e\u91d1\u878d\u8cc7\u7523\u30da\u30a2\uff08\u682a\u5f0f\u3001\u5148\u7269\u3001\u901a\u8ca8\u30da\u30a2\u306a\u3069\uff09\u3092\u9078\u629e\u3057\u3001\u3053\u308c\u3089\u306e\u8cc7\u7523\u9593\u306e\u4fa1\u683c\u5dee\u3084\u8ddd\u96e2\u3092\u5206\u6790\u3057\u307e\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>\u6226\u7565\u306e\u4ed5\u7d44\u307f<\/strong><\/h2>\n\n\n\n<p>\u5178\u578b\u7684\u306a\u5e73\u5747\u56de\u5e30\u6226\u7565\u306b\u306f\u4ee5\u4e0b\u306e\u30b9\u30c6\u30c3\u30d7\u304c\u542b\u307e\u308c\u307e\u3059\uff1a<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u76f8\u95a2\u306e\u3042\u308b\u8cc7\u7523\u306e\u9078\u629e<\/strong><br>\u5f37\u3044\u6b74\u53f2\u7684\u76f8\u95a2\u3092\u6301\u3064\u8cc7\u7523\u30da\u30a2\uff08\u4f8b\u3048\u3070\u3001\u540c\u3058\u30bb\u30af\u30bf\u30fc\u306e2\u3064\u306e\u682a\u5f0f\uff09\u3092\u9078\u3073\u307e\u3059\u3002<\/li>\n\n\n\n<li><strong>\u4fa1\u683c\u5dee\u307e\u305f\u306f\u8ddd\u96e2\u306e\u6e2c\u5b9a<\/strong><br>\u4fa1\u683c\u5dee\u3001\u6a19\u6e96\u504f\u5dee\uff08z\u30b9\u30b3\u30a2\uff09\u3001\u307e\u305f\u306f\u5171\u7a4d\u5206\u5206\u6790\u306a\u3069\u306e\u65b9\u6cd5\u3092\u4f7f\u7528\u3057\u3066\u3001\u8cc7\u7523\u9593\u306e\u4fa1\u683c\u5dee\u3092\u8a08\u7b97\u3057\u307e\u3059\u3002<\/li>\n\n\n\n<li><strong>\u95be\u5024\u306e\u8a2d\u5b9a<\/strong><br>\u4fa1\u683c\u5dee\u306e\u4e0a\u4e0b\u306e\u95be\u5024\u3092\u8a2d\u5b9a\u3057\u307e\u3059\u3002\u3053\u306e\u4fa1\u683c\u5dee\u304c\u95be\u5024\u3092\u8d85\u3048\u308b\u3068\u3001\u56de\u5e30\u306e\u53ef\u80fd\u6027\u3092\u793a\u3059\u30b7\u30b0\u30ca\u30eb\u3068\u306a\u308a\u307e\u3059\u3002<\/li>\n\n\n\n<li><strong>\u53d6\u5f15\u306e\u5b9f\u884c<\/strong><br>\u4fa1\u683c\u5dee\u304c\u95be\u5024\u3092\u8d85\u3048\u308b\u3068\uff1a<ul><li>\u904e\u5c0f\u8a55\u4fa1\u3055\u308c\u305f\u8cc7\u7523\uff08\u5e73\u5747\u4ee5\u4e0b\u306e\u4fa1\u683c\uff09\u3092\u30ed\u30f3\u30b0\uff08\u8cb7\u3044\uff09\u3057\u307e\u3059\u3002<\/li><li>\u904e\u5927\u8a55\u4fa1\u3055\u308c\u305f\u8cc7\u7523\uff08\u5e73\u5747\u4ee5\u4e0a\u306e\u4fa1\u683c\uff09\u3092\u30b7\u30e7\u30fc\u30c8\uff08\u58f2\u308a\uff09\u3057\u307e\u3059\u3002<\/li><\/ul>\u76ee\u6a19\u306f\u3001\u4fa1\u683c\u304c\u5e73\u5747\u306b\u5411\u304b\u3063\u3066\u53ce\u675f\u3059\u308b\u969b\u306b\u5229\u76ca\u3092\u4e0a\u3052\u308b\u3053\u3068\u3067\u3059\u3002<\/li>\n\n\n\n<li><strong>\u30b9\u30c8\u30c3\u30d7\u30ed\u30b9\u3068\u5229\u76ca\u76ee\u6a19\u306e\u8a2d\u5b9a<\/strong><br>\u30b9\u30c8\u30c3\u30d7\u30ed\u30b9\u3068\u30c6\u30a4\u30af\u30d7\u30ed\u30d5\u30a3\u30c3\u30c8\u306e\u30eb\u30fc\u30eb\u3092\u5b9f\u88c5\u3057\u3066\u3001\u30ea\u30b9\u30af\u3092\u7ba1\u7406\u3057\u3001\u4fa1\u683c\u5dee\u304c\u4e88\u60f3\u5916\u306b\u53ce\u675f\u307e\u305f\u306f\u62e1\u5927\u3057\u305f\u5834\u5408\u306b\u5229\u76ca\u3092\u78ba\u4fdd\u3057\u307e\u3059\u3002<\/li>\n<\/ol>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>\u91cd\u8981\u306a\u6982\u5ff5\u3068\u8003\u616e\u4e8b\u9805<\/strong><\/h2>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u3053\u306e\u6226\u7565\u306f\u7d71\u8a08\u7684\u6982\u5ff5\u3068\u6642\u7cfb\u5217\u5206\u6790\u306b\u4f9d\u5b58\u3057\u3066\u3044\u307e\u3059\u3002<\/li>\n\n\n\n<li>\u76f8\u95a2\u95a2\u4fc2\u3092\u8a55\u4fa1\u3057\u3001\u95be\u5024\u3092\u6b63\u78ba\u306b\u8a08\u7b97\u3059\u308b\u305f\u3081\u306b\u306f\u3001\u5927\u898f\u6a21\u306a\u6b74\u53f2\u7684\u30c7\u30fc\u30bf\u30bb\u30c3\u30c8\u304c\u901a\u5e38\u5fc5\u8981\u3067\u3059\u3002<\/li>\n\n\n\n<li>\u9069\u5207\u306a\u30da\u30a2\u9078\u629e\u3001\u95be\u5024\u8abf\u6574\u3001\u30ea\u30b9\u30af\u7ba1\u7406\u304c\u6210\u529f\u306e\u9375\u3068\u306a\u308a\u307e\u3059\u3002<\/li>\n<\/ul>\n\n\n\n<p><strong>\u30ea\u30b9\u30af<\/strong><\/p>\n\n\n\n<p>\u5e73\u5747\u56de\u5e30\u6226\u7565\u306f\u52b9\u679c\u7684\u3067\u3042\u308b\u53ef\u80fd\u6027\u304c\u3042\u308a\u307e\u3059\u304c\u3001\u56fa\u6709\u306e\u30ea\u30b9\u30af\u3092\u4f34\u3044\u307e\u3059\u3002\u4fa1\u683c\u306f\u77ed\u671f\u7684\u306b\u56de\u5e30\u3057\u306a\u3044\u5834\u5408\u304c\u3042\u308b\u304b\u3001\u5e02\u5834\u306e\u69cb\u9020\u7684\u5909\u5316\u306b\u3088\u308a\u65b0\u305f\u306a\u30c8\u30ec\u30f3\u30c9\u306b\u7a81\u5165\u3059\u308b\u3053\u3068\u3082\u3042\u308a\u307e\u3059\u3002\u305d\u306e\u305f\u3081\u3001\u614e\u91cd\u306a\u30d0\u30c3\u30af\u30c6\u30b9\u30c8\u3001\u7d99\u7d9a\u7684\u306a\u30e2\u30c7\u30eb\u306e\u691c\u8a3c\u3001\u304a\u3088\u3073\u30c6\u30af\u30cb\u30ab\u30eb\u6307\u6a19\u306e\u4f7f\u7528\u304c\u4fe1\u983c\u6027\u3068\u53ce\u76ca\u6027\u3092\u9ad8\u3081\u308b\u305f\u3081\u306b\u5fc5\u8981\u3067\u3059\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Java\u30b3\u30fc\u30c9\u4f8b<\/strong><\/h2>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">import java.util.ArrayList;\nimport java.util.List;\n\npublic class MeanReversionStrategyDemo {\n\n    public static void main(String[] args) {\n        List&lt;Double> priceData = new ArrayList&lt;>();  \n\n        for (int i = 0; i &lt; 100; i++) {\n            double price = generateRandomPrice();\n            priceData.add(price);\n        }\n\n        meanReversionStrategy(priceData);\n    }\n\n    private static double generateRandomPrice() {\n        return Math.random() * 100;\n    }\n\n    private static void meanReversionStrategy(List&lt;Double> priceData) {\n        double mean = calculateMean(priceData);  \n\n        for (double price : priceData) {\n            if (price > mean) {\n                System.out.println(\"Sell stocks. Price: \" + price);\n            } else if (price &lt; mean) {\n                System.out.println(\"Buy stocks. Price: \" + price);\n            }\n        }\n    }\n\n    private static double calculateMean(List&lt;Double> prices) {\n        double sum = 0.0;\n        for (double price : prices) {\n            sum += price;\n        }\n        return sum \/ prices.size();\n    }\n}<\/pre>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Python\u30b3\u30fc\u30c9\u4f8b<\/strong><\/h2>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"generic\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">import random\n\ndef generate_random_price():\n    return random.uniform(0, 100)\n\ndef calculate_mean(prices):\n    return sum(prices) \/ len(prices)\n\ndef mean_reversion_strategy(price_data):\n    mean = calculate_mean(price_data)  \n\n    for price in price_data:\n        if price > mean:\n            print(\"Sell stocks. Price:\", price)\n        elif price &lt; mean:\n            print(\"Buy stocks. Price:\", price)\n\ndef main():\n    price_data = []  \n\n    for _ in range(100):\n        price = generate_random_price()\n        price_data.append(price)\n\n    mean_reversion_strategy(price_data)\n\nif __name__ == \"__main__\":\n    main()<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u5e73\u5747\u56de\u5e30\u6226\u7565\u306f\u3001\u91cf\u7684\u53d6\u5f15\u306b\u304a\u3051\u308b\u7d71\u8a08\u7684\u30a2\u30fc\u30d3\u30c8\u30e9\u30fc\u30b8\u30a2\u30d7\u30ed\u30fc\u30c1\u306e\u4e00\u7a2e\u3067\u3059\u3002\u3053\u306e\u6226\u7565\u306f\u3001\u8cc7\u7523\u4fa1\u683c\u304c\u77ed\u671f\u7684\u306a\u9038\u8131\u306e\u5f8c\u306b\u9577\u671f\u7684\u306a\u5e73\u5747\u306b\u623b\u308b\u50be\u5411\u304c\u3042\u308b\u3068\u3044\u3046\u8003\u3048\u306b\u57fa\u3065\u3044\u3066\u3044\u307e\u3059\u3002\u57fa\u672c\u7684\u306a\u524d\u63d0\u306f\u3001\u4fa1\u683c\u304c\u6b74\u53f2\u7684\u306a\u5e73\u5747\u304b\u3089\u5927\u304d\u304f\u9038\u8131\u3057 [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":127,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[7],"tags":[],"class_list":["post-126","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-guide"],"featured_image_src":"https:\/\/i0.wp.com\/blog.alltick.co\/ja-jp\/wp-content\/uploads\/sites\/2\/2025\/06\/mean-reversion-trading-1024x573-1.png?fit=1024%2C573&ssl=1","author_info":{"display_name":"admin","author_link":"https:\/\/blog.alltick.co\/ja-jp\/author\/admin\/"},"_links":{"self":[{"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/posts\/126","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/comments?post=126"}],"version-history":[{"count":1,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/posts\/126\/revisions"}],"predecessor-version":[{"id":128,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/posts\/126\/revisions\/128"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/media\/127"}],"wp:attachment":[{"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/media?parent=126"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/categories?post=126"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.alltick.co\/ja-jp\/wp-json\/wp\/v2\/tags?post=126"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}