{"id":1569,"date":"2024-10-30T07:31:00","date_gmt":"2024-10-29T23:31:00","guid":{"rendered":"https:\/\/blog.laoyulaoyu.top\/?p=1569"},"modified":"2024-10-05T17:32:29","modified_gmt":"2024-10-05T09:32:29","slug":"%e6%89%8b%e6%8a%8a%e6%89%8b%e6%95%99%e4%bd%a0-ai-%e9%a1%be%e6%8a%95%ef%bc%9a-python-%e5%8a%a9%e5%8a%9b%ef%bc%8c%e8%bd%bb%e6%9d%be%e8%bf%88%e5%85%a5%e7%ae%97%e6%b3%95%e4%ba%a4%e6%98%93%e5%91%98","status":"publish","type":"post","link":"https:\/\/laoyulaoyu.com\/index.php\/2024\/10\/30\/%e6%89%8b%e6%8a%8a%e6%89%8b%e6%95%99%e4%bd%a0-ai-%e9%a1%be%e6%8a%95%ef%bc%9a-python-%e5%8a%a9%e5%8a%9b%ef%bc%8c%e8%bd%bb%e6%9d%be%e8%bf%88%e5%85%a5%e7%ae%97%e6%b3%95%e4%ba%a4%e6%98%93%e5%91%98\/","title":{"rendered":"\u624b\u628a\u624b\u6559\u4f60 AI \u987e\u6295\uff1a Python \u52a9\u529b\uff0c\u8f7b\u677e\u8fc8\u5165\u7b97\u6cd5\u4ea4\u6613\u5458\u4e4b\u95e8"},"content":{"rendered":"\n<p>\u4f5c\u8005\uff1a<a href=\"https:\/\/www.laoyulaoyu.com\/\" target=\"_blank\" rel=\"noreferrer noopener\">\u8001\u4f59\u635e\u9c7c<\/a><\/p>\n\n\n\n<p><strong><mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-cyan-bluish-gray-color\">\u539f\u521b\u4e0d\u6613\uff0c\u8f6c\u8f7d\u8bf7\u6807\u660e\u51fa\u5904\u53ca\u539f\u4f5c\u8005\u3002<\/mark><\/strong><\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/www.laoyulaoyu.com\/wp-content\/uploads\/2024\/10\/1-2.png\" alt=\"\" class=\"wp-image-2369\"\/><\/figure>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<pre class=\"wp-block-verse\"><strong>\u5199\u5728\u524d\u9762\u7684\u8bdd\uff1a<\/strong>\u672c\u6587\u4ecb\u7ecd\u4e86\u5982\u4f55\u4f7f\u7528 Python \u548c\u4e13\u4e1a\u6570\u636e\u6e90\uff08\u5982 Alpha Vantage\uff09\u6765\u83b7\u53d6\u9ad8\u8d28\u91cf\u6570\u636e\uff0c\u4ee5\u53ca\u5982\u4f55\u6784\u5efa\u548c\u5206\u6790\u91cf\u5316\u4ea4\u6613\u7b56\u7565\uff0c\u7279\u522b\u662f\u5f00\u76d8\u533a\u95f4\u7a81\u7834\uff08ORB\uff09\u7b56\u7565\uff0c\u5e76\u901a\u8fc7\u5b9e\u9645\u4ee3\u7801\u793a\u4f8b\u5c55\u793a\u4e86\u5982\u4f55\u8ba1\u7b97\u4ef7\u683c\u7f3a\u53e3\u3001\u6210\u4ea4\u91cf\u3001\u79fb\u52a8\u5e73\u5747\u7ebf\u7b49\u5173\u952e\u6307\u6807<mark style=\"background-color:rgba(0, 0, 0, 0)\" class=\"has-inline-color has-vivid-cyan-blue-color\">\uff0c\u4ee5\u5e2e\u52a9\u5165\u95e8\u6570\u636e\u4ea4\u6613\u8005\u505a\u51fa\u66f4\u7b80\u5355\u7684\u4ea4\u6613\u51b3\u7b56<\/mark>\u3002<\/pre>\n<\/blockquote>\n\n\n\n<p>\u5982\u679c\u60a8\u7740\u624b\u51c6\u5907\u5f00\u59cb\u4f7f\u7528 Python \u7f16\u5199\u80a1\u7968\u4ea4\u6613\u7b97\u6cd5\uff0c\u90a3\u4e48\u60a8\u5c06\u9762\u4e34\u7684\u6700\u7d27\u8feb\u95ee\u9898\u662f\uff1a\u6211\u9700\u8981\u4ec0\u4e48\u6837\u7684\u6570\u636e\uff0c\u6211\u5728\u54ea\u91cc\u53ef\u4ee5\u627e\u5230\u8fd9\u4e9b\u6570\u636e\u3002\u6211\u82b1\u4e86\u5f88\u591a\u65f6\u95f4\u6765\u7814\u7a76\u8fd9\u4e2a\u95ee\u9898\uff0c\u5f88\u4e50\u610f\u4e3a\u60a8\u63d0\u4f9b\u5e2e\u52a9\u3002<\/p>\n\n\n\n<p>\u5728\u672c\u6587\u4e2d\uff0c\u6211\u4eec\u5c06\u6784\u5efa\u4e00\u4e2a\u8d85\u7ea7\u5168\u9762\u7684\u6570\u636e\u6846\u67b6\uff0c\u5176\u4e2d\u5305\u542b\u521b\u5efa\u5236\u80dc\u7b97\u6cd5\u6240\u9700\u7684\u4e00\u5207\u3002\u4f46\u66f4\u91cd\u8981\u7684\u662f\uff0c\u6211\u5728\u8fd9\u91cc\u5206\u4eab\u7684\u4ee3\u7801\u8bbe\u8ba1\u5f97\u975e\u5e38\u5bb9\u6613\u9002\u5e94\u4e0d\u540c\u7684\u65f6\u95f4\u6846\u67b6\uff0c\u5e0c\u671b\u4f60\u5728\u9700\u8981\u6293\u53d6\u81ea\u5df1\u7684\u6570\u636e\u65f6\u53ef\u4ee5\u91cd\u590d\u4f7f\u7528\u3002<\/p>\n\n\n\n<p>\u5e02\u9762\u4e0a\u6709\u5f88\u591a\u80a1\u7968\u6570\u636e API\uff0c\u4f46\u5bf9\u4e8e\u5b9a\u91cf\u5206\u6790\uff0c\u6211\u63a8\u8350 <a href=\"https:\/\/www.alphavantage.co\/\">https:\/\/www.alphavantage.co\/<\/a>\uff0c\u56e0\u4e3a\u5b83\u5e26\u6765\u4e86\u5f88\u591a\u5df2\u7ecf\u8ba1\u7b97\u597d\u7684\u6307\u6807\uff0c\u800c\u4e14\u76d8\u4e2d\u7c92\u5ea6\u53ef\u8fbe 1 \u5206\u949f\uff0c\u8fd9\u662f\u5b9a\u91cf\u5206\u6790\u4eba\u5458\u7684\u5fc5\u5907\u5de5\u5177\u3002<\/p>\n\n\n\n<p>\u5177\u4f53\u5185\u5bb9\u53ef\u4ee5\u770b\u6211\u8fd9\u7bc7\u6587\u7ae0\uff1a\u300a<a href=\"https:\/\/www.laoyulaoyu.com\/index.php\/2024\/08\/19\/%e6%89%8b%e6%8a%8a%e6%89%8b%e6%95%99%e4%bd%a0ai%e9%a1%be%e6%8a%95%ef%bc%9a%e5%8f%91%e7%8e%b0%e4%b8%80%e4%b8%aa%e9%ab%98%e8%b4%a8%e9%87%8f%e7%9a%84%e9%87%91%e8%9e%8d%e6%95%b0%e6%8d%ae%e6%ba%90\/\">\u624b\u628a\u624b\u6559\u4f60ai\u987e\u6295\uff1a\u53d1\u73b0\u4e00\u4e2a\u9ad8\u8d28\u91cf\u7684\u91d1\u878d\u6570\u636e\u6e90<\/a>\u300b<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>\u4e00\u3001\u83b7\u53d6\u6570\u636e<\/strong><\/h3>\n\n\n\n<p>\u4e0b\u9762\u7684\u4ee3\u7801\u5c06\u81ea\u52a8\u6293\u53d6\u60a8\u9009\u62e9\u7684\u80a1\u7968\u6570\u636e\uff0c\u5e76\u5c06\u5b83\u4eec\u8fde\u63a5\u5230\u4e00\u4e2a\u6570\u636e\u6846\u4e2d\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>!pip install alpha_vantage\nfrom datetime import datetime\nfrom datetime import timedelta\n\nfrom alpha_vantage.timeseries import TimeSeries\nimport requests\nimport pandas as pd\nimport numpy as np\nimport datetime\nfrom re import M\nimport requests\napi_key = 'MY_ALPHA_VANTAGE_KEY'\n\ndef get_last_n_years_months(n):\n    current_date = datetime.now()\n    start_date = current_date - timedelta(days=n*365)  # Approximate start date n years ago\n    months = &#91;]\n\n    while start_date &lt;= current_date:\n        month = start_date.strftime('%Y-%m')\n        months.append(month)\n        start_date += timedelta(days=32)  # Move to the next month\n        start_date = start_date.replace(day=1)  # Set to the first day of the next month\n\n    return months\n\ndef fetch_stock_data(ticker, n_years, api_key):\n    period = get_last_n_years_months(n_years)\n    final_df = pd.DataFrame()\n\n    for i in period:\n        print(f'Getting data for stock {ticker} and period {i}')\n        url = f'https:\/\/www.alphavantage.co\/query?function=TIME_SERIES_INTRADAY&amp;symbol={ticker}&amp;interval=5min&amp;month={i}&amp;outputsize=full&amp;apikey={api_key}'\n        r = requests.get(url)\n\n        if r.status_code == 200:\n            data = r.json()\n            if 'Time Series (5min)' in data:\n                time_series = data&#91;'Time Series (5min)']\n                df = pd.DataFrame.from_dict(time_series, orient='index')\n                df.index = pd.to_datetime(df.index)\n                df.columns = &#91;'open', 'high', 'low', 'close', 'volume']\n                df = df.apply(pd.to_numeric)\n                df&#91;'ticker'] = ticker  # Add ticker column to identify the stock\n                final_df = pd.concat(&#91;final_df, df])\n            else:\n                print(f\"No 'Time Series (5min)' data found for {i}\")\n        else:\n            print(f\"Failed to fetch data for {i}, status code: {r.status_code}\")\n\n    # Filter out data when market is closed\n    final_df = final_df.between_time('09:30', '15:55')\n\n    return final_df\n\n# Function to fetch and concatenate data for multiple tickers\ndef fetch_and_concatenate_data(tickers, n_years, api_key):\n    combined_df = pd.DataFrame()\n    for ticker in tickers:\n        df = fetch_stock_data(ticker, n_years, api_key)\n        combined_df = pd.concat(&#91;combined_df, df])\n    return combined_df<\/code><\/code><\/pre>\n\n\n\n<p>\u9996\u5148\u6211\u4eec\u521b\u5efa\u4e86\u4e00\u4e2a\u51fd\u6570 &#8220;get_last_n_years_months&#8221;\uff0c\u8be5\u51fd\u6570\u83b7\u53d6\u8fc7\u53bb\u82e5\u5e72\u5e74\u7684\u6570\u636e\u5e76\u521b\u5efa\u6708\u65e5\u671f\uff0c\u4ee5\u4fbf\u5728 API \u8c03\u7528\u4e2d\u4f7f\u7528\u3002\u901a\u5e38\uff0c\u5728\u8fdb\u884c\u5386\u53f2\u5206\u6790\u65f6\uff0c\u6700\u597d\u4f7f\u7528\u8db3\u591f\u591a\u7684\u5e74\u6570\uff0c\u4ee5\u5305\u62ec\u51e0\u4e2a\u718a\u5e02\u548c\u725b\u5e02\uff0c\u6211\u559c\u6b22\u81f3\u5c11\u9009\u62e9 5 \u5e74\u8de8\u5ea6\u3002<\/p>\n\n\n\n<p>\u4e4b\u540e\uff0c\u6211\u4eec\u4f7f\u7528 &#8220;fetch_stock_data &#8220;\u51fd\u6570\u8c03\u7528\u5e94\u7528\u7a0b\u5e8f\u63a5\u53e3\uff0c\u5728\u672c\u4f8b\u4e2d\uff0c\u6211\u4eec\u5c06\u4f7f\u7528 5 \u5206\u949f\u95f4\u9694\u7684\u6570\u636e\uff0c\u4f46\u60a8\u4e5f\u53ef\u4ee5\u6839\u636e\u60f3\u8981\u521b\u5efa\u7684\u7b97\u6cd5\u7c7b\u578b\u9009\u62e9\u4efb\u4f55\u4e0d\u540c\u7684\u95f4\u9694\u3002<\/p>\n\n\n\n<p>\u6700\u540e\uff0c&#8221;fetch_and_concatenate_data &#8220;\u51fd\u6570\u5c06\u6570\u636e\u8fde\u63a5\u5230\u4e00\u4e2a\u6570\u636e\u5e27\u4e2d\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>\u4e8c\u3001\u8ba1\u7b97\u6bcf\u65e5\u95f4\u9699\u548c\u4ea4\u6613\u91cf<\/strong><\/h3>\n\n\n\n<p>\u5728\u591a\u6570\u5206\u6790\u91cc\uff0c\u6709\u4e2a\u7279\u522b\u91cd\u8981\u7684\u73af\u8282\u5c31\u662f\u7b97\u51fa\u76d8\u524d\u8df3\u7a7a\u7f3a\u53e3\uff0c\u4e5f\u5c31\u662f\u80a1\u7968\u4ef7\u683c\u548c\u6210\u4ea4\u91cf\u8ddf\u4e0a\u4e2a\u4ea4\u6613\u65e5\u6536\u76d8\u4ef7\u4e4b\u95f4\u7684\u5dee\u503c\u3002\u5c24\u5176\u662f\u5728\u5404\u79cd\u65e5\u5185\u4ea4\u6613\u7b97\u6cd5\u91cc\uff0c\u4f60\u5f97\u7559\u610f\u7f3a\u53e3\u7684\u53d8\u5316\u3002<\/p>\n\n\n\n<p><em>\u8bf4\u5230\u5e95\uff0c\u6210\u529f\u7684\u65e5\u95f4\u4ea4\u6613\u8005\u5e76\u4e0d\u662f\u5f04\u51fa\u4e2a\u6bcf\u5929\u90fd\u80fd\u5b8c\u7f8e\u4ea4\u6613\u80a1\u7968\u7684\u7b97\u6cd5\u3002\u4ed6\u4eec\u5f00\u53d1\u7684\u662f\u80fd\u5728\u4efb\u4f55\u7279\u5b9a\u65f6\u5019\u627e\u5230\u5b8c\u7f8e\u80a1\u7968\u7684\u7b97\u6cd5\u3002\u4e3a\u5565\u5462\uff0c\u56e0\u4e3a\u5f88\u591a\u65f6\u5019\uff0c\u67d0\u53ea\u80a1\u7968\u6216\u67d0\u4e2a\u6307\u6570\u51e0\u4e4e\u90fd\u6ca1\u4ec0\u4e48\u53d8\u5316\uff0c\u4e0d\u7ba1\u4f60\u7684\u7b97\u6cd5\u591a\u725b\uff0c\u5c31\u7b97\u4f60\u5224\u65ad\u5bf9\u4e86\u53d8\u52a8\u65b9\u5411\uff0c\u76c8\u5229\u4e5f\u4f1a\u5f88\u5c11\u3002<\/em><\/p>\n\n\n\n<p>\u8981\u5f00\u53d1\u7b97\u6cd5\u6765\u627e\u5230\u6bcf\u5929\u4ea4\u6613\u7684\u5b8c\u7f8e\u80a1\u7968\uff0c\u5c31\u9700\u8981\u67e5\u770b\u76d8\u524d\u7684\u4ef7\u683c\u548c\u6210\u4ea4\u91cf\u8d70\u52bf\uff0c\u627e\u5230\u53ef\u80fd\u5728\u5f53\u524d\u4ea4\u6613\u65f6\u6bb5\u5927\u5e45\u6ce2\u52a8\u3001\u5e26\u6765\u5de8\u5927\u83b7\u5229\u673a\u4f1a\u7684\u80a1\u7968\u3002<\/p>\n\n\n\n<p>\u6211\u4eec\u901a\u8fc7 Python \u51fd\u6570\u83b7\u53d6\u66f4\u591a\u4fe1\u606f\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code># Calculate the gap and previous_volume\ndef calculate_gap_and_previous_volume(df):\n    gap_list = &#91;]\n    previous_volume_list = &#91;]\n    for ticker in df&#91;'ticker'].unique():\n        ticker_df = df&#91;df&#91;'ticker'] == ticker]\n        ticker_df = ticker_df.sort_index()\n\n        daily_volume = ticker_df&#91;'volume'].resample('D').sum()\n        daily_volume = daily_volume&#91;daily_volume &gt; 0]  # Exclude days with zero volume\n        avg_daily_volume = daily_volume.mean()\n\n        for date in ticker_df.index.normalize().unique():\n            day_data = ticker_df&#91;ticker_df.index.normalize() == date]\n            if not day_data.empty:\n                open_price = day_data&#91;'open'].iloc&#91;0]\n                previous_close = ticker_df&#91;ticker_df.index &lt; date]&#91;'close'].iloc&#91;-1] if not ticker_df&#91;ticker_df.index &lt; date].empty else float('nan')\n                gap = (open_price - previous_close) \/ previous_close * 100 if not pd.isna(previous_close) else float('nan')\n                gap_list.append({'ticker': ticker, 'date': date, 'gap': gap})\n\n                # Find the last trading day with non-zero volume\n                prev_date = date - timedelta(days=1)\n                while prev_date not in daily_volume.index or daily_volume&#91;prev_date] == 0:\n                    prev_date -= timedelta(days=1)\n                    if prev_date &lt; daily_volume.index.min():\n                        prev_date = pd.NaT\n                        break\n                previous_day_volume = daily_volume&#91;prev_date] if prev_date in daily_volume.index and not pd.isna(prev_date) else float('nan')\n                previous_volume = previous_day_volume \/ avg_daily_volume if not pd.isna(previous_day_volume) else float('nan')\n                previous_volume_list.append({'ticker': ticker, 'date': date, 'previous_volume': previous_volume})\n\n    gap_df = pd.DataFrame(gap_list)\n    previous_volume_df = pd.DataFrame(previous_volume_list)\n    df = df.reset_index().merge(gap_df, how='left', left_on=&#91;'ticker', df.index.normalize()], right_on=&#91;'ticker', 'date']).set_index('index')\n    df = df.reset_index().merge(previous_volume_df, how='left', left_on=&#91;'ticker', df.index.normalize()], right_on=&#91;'ticker', 'date']).set_index('index')\n\n    # Clean up merged columns\n    df = df.drop(columns=&#91;'date_x', 'date_y'])\n\n    return df<\/code><\/code><\/pre>\n\n\n\n<p>\u8ba9\u6211\u4eec\u62ff\u4e00\u4e9b\u70ed\u95e8\u80a1\u7968\uff08\u7279\u65af\u62c9\u3001\u82f1\u4f1f\u8fbe\u548c Meta \u80a1\u7968\uff09\u6765\u505a\u4f8b\u5b50\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/www.laoyulaoyu.com\/wp-content\/uploads\/2024\/10\/image-10.png\" alt=\"\" class=\"wp-image-2370\"\/><\/figure>\n\n\n\n<p>\u4f7f\u7528\u8fd9\u4e9b\u51fd\u6570\u540e\uff0c\u6211\u4eec\u5c31\u5f97\u5230\u4e86\u8fd9\u4e2a\u6570\u636e\u5e27\uff08\u5305\u542b\u524d\u4e00\u5929\u4ef7\u683c\u5dee\u8ddd\u548c\u76f8\u5bf9\u65e5\u6210\u4ea4\u91cf\u7684\u6570\u636e\uff09\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/www.laoyulaoyu.com\/wp-content\/uploads\/2024\/10\/image-11.png\" alt=\"\" class=\"wp-image-2371\"\/><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\"><br><strong>\u4e09\u3001\u8ba1\u7b97\u57fa\u672c\u6307\u6807<\/strong><\/h3>\n\n\n\n<p>\u8ba9\u6211\u4eec\u7528 Python \u8ba1\u7b97\u4e00\u4e9b\u5e38\u7528\u4e8e\u5b9a\u91cf\u5206\u6790\u7684\u6700\u91cd\u8981\u7684\u6280\u672f\u6307\u6807\u3002\u5728\u672c\u793a\u4f8b\u4e2d\uff0c\u6211\u4eec\u5c06\u8ba1\u7b97\u5f00\u76d8\u7a81\u7834\u7b56\u7565\u7684\u6307\u6807\uff0c\u8be5\u7b56\u7565\u662f\u6700\u8457\u540d\u3001\u6700\u8d5a\u94b1\u7684\u65e5\u5185\u4ea4\u6613\u6280\u5de7\u4e4b\u4e00\u3002\u8be5\u7b56\u7565\u5305\u62ec\u5728\u5f00\u76d8\u533a\u95f4\u7684\u6da8\u8dcc\u5e45\u9650\u5236\u65f6\u4e70\u5165\u80a1\u7968\uff0c\u53ef\u7528\u4e8e 2\u30015\u300115\u300130 \u6216 60 \u5206\u949f\u7684\u533a\u95f4\u3002<\/p>\n\n\n\n<p>\u53ef\u4ee5\u4f7f\u7528\u4ee5\u4e0b\u4ee3\u7801\u8ba1\u7b97\u79fb\u52a8\u5e73\u5747\u7ebf\u548c\u6210\u4ea4\u91cf\u52a0\u6743\u79fb\u52a8\u5e73\u5747\u7ebf\uff0c\u4ee5\u53ca\u5f00\u76d8\u533a\u95f4\u7684\u6307\u6807\uff0c\u5982\u6210\u4ea4\u91cf\u3001\u5bbd\u5ea6\u3001\u6ce2\u52a8\u7387\u7b49\uff0c\u8fd9\u4e9b\u6307\u6807\u5bf9\u4e8e\u4e86\u89e3\u5f00\u76d8\u540e\u7b2c\u4e00\u5206\u949f\u5185\u80a1\u7968\u7684\u8d70\u52bf\u975e\u5e38\u91cd\u8981\u3002<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code># Prepare the DataFrame with necessary calculations\ndef calculate_moving_averages(df):\n    df&#91;'MA_5'] = df&#91;'close'].rolling(window=5).mean()\n    df&#91;'MA_10'] = df&#91;'close'].rolling(window=10).mean()\n    df&#91;'MA_20'] = df&#91;'close'].rolling(window=20).mean()\n\n    # Adding the distance from moving averages as percentages\n    df&#91;'distance_MA_5_pct'] = (df&#91;'close'] - df&#91;'MA_5']) \/ df&#91;'MA_5'] * 100\n    df&#91;'distance_MA_10_pct'] = (df&#91;'close'] - df&#91;'MA_10']) \/ df&#91;'MA_10'] * 100\n    df&#91;'distance_MA_20_pct'] = (df&#91;'close'] - df&#91;'MA_20']) \/ df&#91;'MA_20'] * 100\n\n    return df\n\ndef calculate_vwap(df):\n    df&#91;'VWAP'] = (df&#91;'volume'] * (df&#91;'high'] + df&#91;'low'] + df&#91;'close']) \/ 3).cumsum() \/ df&#91;'volume'].cumsum()\n    return df\n\ndef prepare_dataframe(df):\n    df.index = pd.to_datetime(df.index)\n    df = calculate_moving_averages(df)\n    df = calculate_vwap(df)\n    return df\n\n# Function to calculate indicators for each stock\ndef prepare_indicators(ticker, df, opening_range_duration):\n    opening_range_df_list = &#91;]\n    for day in df.index.normalize().unique():\n        day_data = df&#91;df.index.normalize() == day]\n\n        # Ensure data is sorted by timestamp\n        day_data = day_data.sort_index()\n\n        if len(day_data) &lt; opening_range_duration:\n            continue\n\n        # Select the correct opening range\n        opening_range = day_data.iloc&#91;:opening_range_duration]\n        opening_range_high = opening_range&#91;'high'].max()\n        opening_range_low = opening_range&#91;'low'].min()\n        opening_range_close = opening_range&#91;'close'].iloc&#91;-1]\n        opening_price = opening_range&#91;'open'].iloc&#91;0]\n        opening_range_width = ((opening_range_high - opening_range_low) \/ opening_price) * 100\n        opening_range_volatility = opening_range&#91;'close'].std() if opening_range_duration &gt; 1 else 0\n        opening_range_volume = opening_range&#91;'volume'].sum()\n        opening_range_avg_volume = opening_range_volume \/ opening_range_duration\n\n        post_opening_range = day_data.iloc&#91;opening_range_duration:]\n\n        breakout_idx = None\n        breakout_type = None\n        for idx in post_opening_range.index:\n            if post_opening_range.loc&#91;idx]&#91;'low'] &gt; opening_range_high:\n                breakout_idx = idx\n                breakout_type = 'bullish'\n                break\n            elif post_opening_range.loc&#91;idx]&#91;'high'] &lt; opening_range_low:\n                breakout_idx = idx\n                breakout_type = 'bearish'\n                break\n\n        if breakout_idx is None:\n            continue\n\n        breakout_data = day_data.loc&#91;breakout_idx]\n\n        next_1_hour = day_data.loc&#91;breakout_idx:].iloc&#91;1:13]\n        if breakout_type == 'bullish':\n            max_price_next_1_hour = next_1_hour&#91;'high'].max() if not next_1_hour.empty else np.nan\n            target = (max_price_next_1_hour - breakout_data&#91;'close']) \/ breakout_data&#91;'close'] * 100 if not np.isnan(max_price_next_1_hour) else np.nan\n        else:\n            min_price_next_1_hour = next_1_hour&#91;'low'].min() if not next_1_hour.empty else np.nan\n            target = (breakout_data&#91;'close'] - min_price_next_1_hour) \/ breakout_data&#91;'close'] * 100 if not np.isnan(min_price_next_1_hour) else np.nan\n\n        # Calculate percentage change of breakout close price from opening range close price\n        price_change_during_breakout = (breakout_data&#91;'close'] - opening_range_close) \/ opening_range_close * 100\n\n        # Calculate direction consistency in the opening range\n        if breakout_type == 'bullish':\n            direction_consistency = (opening_range&#91;'close'] &gt; opening_range&#91;'open']).sum() \/ len(opening_range)\n        else:\n            direction_consistency = (opening_range&#91;'close'] &lt; opening_range&#91;'open']).sum() \/ len(opening_range)\n\n        # Calculate volume relative to the average volume during the opening range\n        volume_relative_to_avg = (opening_range_volume - opening_range_avg_volume) \/ opening_range_avg_volume * 100\n\n        # Calculate VWAP as a percentage relative to the close price\n        vwap_end_pct = (breakout_data&#91;'VWAP'] - breakout_data&#91;'close']) \/ breakout_data&#91;'close'] * 100\n        vwap_at_breakout_pct = (breakout_data&#91;'VWAP'] - breakout_data&#91;'close']) \/ breakout_data&#91;'close'] * 100\n\n        row_data = {\n            'ticker': ticker,\n            'date': day,\n            'opening_range_width': opening_range_width,\n            'opening_range_volatility': opening_range_volatility,\n            'direction_consistency': direction_consistency,\n            'gap': df.loc&#91;day_data.index&#91;0], 'gap'],\n            'previous_volume': df.loc&#91;day_data.index&#91;0], 'previous_volume'],\n            'price_change_during_breakout': price_change_during_breakout,\n            'volume_relative_to_avg': volume_relative_to_avg,\n            'distance_MA_5_pct': breakout_data&#91;'distance_MA_5_pct'],\n            'distance_MA_10_pct': breakout_data&#91;'distance_MA_10_pct'],\n            'distance_MA_20_pct': breakout_data&#91;'distance_MA_20_pct'],\n            'VWAP_End_pct': vwap_end_pct,\n            'VWAP_at_Breakout_pct': vwap_at_breakout_pct,\n            'breakout_type': breakout_type,\n            'target': target\n        }\n\n        opening_range_df_list.append(row_data)\n\n    return opening_range_df_list\n\n\n# Apply the prepare_indicators function to each stock\ndef analyze_combined_data(df, opening_range_duration):\n    opening_range_df_list = &#91;]\n    for ticker in df&#91;'ticker'].unique():\n        ticker_df = df&#91;df&#91;'ticker'] == ticker]\n        opening_range_df_list.extend(prepare_indicators(ticker, ticker_df, opening_range_duration))\n    return pd.DataFrame(opening_range_df_list)<\/code><\/code><\/pre>\n\n\n\n<p>\u8ba9\u6211\u4eec\u770b\u770b\u5b83\u5982\u4f55\u4f7f\u7528 15 \u5206\u949f\u5f00\u4ed3\u533a\u95f4\u7b56\u7565\u7684\u6570\u636e\uff08\u5373 5 \u5206\u949f\u6570\u636e\u7684 3 \u4e2a\u533a\u95f4\uff09\uff1a<\/p>\n\n\n\n<figure class=\"wp-block-image size-full\"><img decoding=\"async\" src=\"https:\/\/www.laoyulaoyu.com\/wp-content\/uploads\/2024\/10\/image-12.png\" alt=\"\" class=\"wp-image-2372\"\/><\/figure>\n\n\n\n<p>\u5982\u60a8\u6240\u89c1\uff0c\u6211\u4eec\u5728\u4e0a\u9762\u6784\u5efa\u4e86\u4e00\u4e2a\u975e\u5e38\u5168\u9762\u7684\u6570\u636e\u6846\u67b6\uff0c\u4f7f\u7528\u4e86\u79fb\u52a8\u5e73\u5747\u7ebf\u7b49\u5e38\u7528\u6307\u6807\uff0c\u4ee5\u53ca\u5176\u4ed6\u5bf9\u6211\u4eec\u6709\u610f\u4e49\u7684\u6307\u6807\u3002\u5728\u7814\u7a76\u4e2d\uff0c\u4f60\u53ea\u9700\u95ee\u95ee\u81ea\u5df1\uff0c\u4f60\u60f3\u6d4b\u8bd5\u7684\u5047\u8bbe\u662f\u4ec0\u4e48\uff1f\u5728\u8fd9\u79cd\u60c5\u51b5\u4e0b\uff0c\u6211\u4eec\u8981\u6d4b\u8bd5\u7684\u4fe1\u5ff5\u5c31\u662f ORB \u7b56\u7565\u4e2d\u6240\u5305\u542b\u7684\u4fe1\u5ff5\u3002<\/p>\n\n\n\n<p>\u8bf7\u6ce8\u610f\uff0c\u4e3a\u8fbe\u5230\u76ee\u7684\uff0c\u6211\u521b\u5efa\u4e86\u4e00\u4e2a\u76ee\u6807\uff0c\u7528\u6765\u8861\u91cf\u6211\u4eec\u7528\u8fd9\u884c\u4ee3\u7801\u4e70\u5165\u770b\u6da8\u7a81\u7834\u6216\u5356\u51fa\u770b\u8dcc\u7a81\u7834\u540e\uff0c\u5728\u63a5\u4e0b\u6765\u7684 60 \u5206\u949f\u5185\u53ef\u4ee5\u83b7\u5f97\u7684\u6700\u5927\u5229\u6da6\uff1a<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code><code>target = (breakout_data&#91;'close'] - min_price_next_1_hour) \/ breakout_data&#91;'close'] * 100 if not np.isnan(min_price_next_1_hour) else np.nan<\/code><\/code><\/pre>\n\n\n\n<p>\u60a8\u53ef\u4ee5\u6839\u636e\u81ea\u5df1\u7684\u559c\u597d\u8fdb\u884c\u8c03\u6574\uff0c\u4f46\u901a\u5e38 ORB \u5305\u62ec\u5728\u7a81\u7834\u540e\u77ed\u65f6\u95f4\u5185\u6301\u4ed3\u3002\u5982\u679c\u4ea4\u6613\u6210\u529f\uff08\u80a1\u7968\u5411\u60a8\u671f\u671b\u7684\u65b9\u5411\u79fb\u52a8\uff09\uff0c\u5c31\u5fc5\u987b\u51b3\u5b9a\u4f55\u65f6\u79bb\u573a\u3002<\/p>\n\n\n\n<p>\u76f8\u53cd\uff0c\u5982\u679c\u4ea4\u6613\u4e0e\u60a8\u7684\u9884\u671f\u80cc\u9053\u800c\u9a70\uff0c\u60a8\u5c31\u5fc5\u987b\u51b3\u5b9a\u4f55\u65f6\u51fa\u5c40\uff0c\u5728\u635f\u5931\u8fc7\u5927\u4e4b\u524d\u51cf\u5c11\u635f\u5931\u3002<\/p>\n\n\n\n<p><em>\u4e00\u822c\u6765\u8bf4\uff0c\u65e5\u95f4\u4ea4\u6613\u8005\u4f1a\u9009\u62e9 1:3 \u7684\u98ce\u9669\u4e0e\u56de\u62a5\u6bd4\u4f8b\uff0c\u8fd9\u53ef\u80fd\u8868\u793a\u4ed6\u4eec\u4f1a\u5728\u4e8f\u635f 1%\u7684\u65f6\u5019\u5e73\u6389\u4ed3\u4f4d\uff0c\u5728\u76c8\u5229\u8fbe\u5230 3%\u7684\u65f6\u5019\u83b7\u5229\u4e86\u7ed3\uff0c\u6216\u8005\u4ed6\u4eec\u4f1a\u5728\u4e8f\u635f\u8d85\u8fc7 0.5%\u7684\u65f6\u5019\u5c31\u5e73\u4ed3\uff0c\u5728\u76c8\u5229\u8d85\u8fc7 1.5%\u7684\u65f6\u5019\u8d5a\u4e00\u7b14\u3002<\/em><\/p>\n\n\n\n<p>\u5c31\u662f\u4e3a\u4f55\u6211\u4eec\u8981\u7814\u7a76\u4f60\u6240\u80fd\u83b7\u53d6\u7684\u6700\u5927\u5229\u6da6\uff0c\u56e0\u4e3a\u8fd9\u662f\u51b3\u5b9a\u4f55\u4e3a\u5408\u7406\u79bb\u573a\u4ef7\u683c\u3001\u5bf9\u5229\u6da6\u611f\u5230\u6ee1\u8db3\u4ee5\u53ca\u4f55\u79cd\u7a0b\u5ea6\u7684\u4e8f\u635f\u662f\u6211\u4eec\u80fd\u591f\u63a5\u53d7\u6216\u65e0\u6cd5\u63a5\u53d7\u7684\u5173\u952e\u8981\u7d20\u3002<\/p>\n\n\n\n<p>\u901a\u8fc7\u6570\u636e\u7814\u7a76\uff0c\u6211\u4eec\u53ef\u4ee5\u786e\u5b9a\u4ec0\u4e48\u662f\u771f\u6b63\u7684\u6700\u4f73\u503c\uff0c\u5e76\u6839\u636e\u56de\u6eaf\u6d4b\u8bd5\u505a\u51fa\u660e\u667a\u7684\u51b3\u5b9a\u3002<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>\u56db\u3001\u89c2\u70b9\u603b\u7ed3<\/strong><\/h3>\n\n\n\n<p>\u73b0\u5728\uff0c\u60a8\u4e0d\u5fc5\u56e0\u4e3a\u535a\u4e3b\u8fd9\u4e48\u8bf4\uff0c\u5c31\u575a\u4fe1\u5f00\u4ed3\u533a\u95f4\u7a81\u7834\uff08\u6216\u4efb\u4f55\u5176\u4ed6\u7b56\u7565\uff09\u662f\u6709\u6548\u7684\u3002\u6b63\u786e\u7684\u91cf\u5316\u601d\u7ef4\u5e94\u5efa\u7acb\u5728\u5bf9\u6570\u636e\u53ca\u81ea\u8eab\u7814\u7a76\u5145\u6ee1\u4fe1\u5fc3\u7684\u57fa\u77f3\u4e4b\u4e0a\u3002\u90a3\u4e48\uff0c\u5c31\u8ba9\u6211\u4eec\u4eb2\u81ea\u6765\u77a7\u77a7\u8fd9\u4e2a\u7cbe\u7f8e\u7684\u6570\u636e\u6846\u67b6\u6240\u80fd\u544a\u77e5\u6211\u4eec\u7684\u5185\u5bb9\u5427\u3002<\/p>\n\n\n\n<p>\u5728\u7406\u60f3\u7684\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u4e00\u53ea\u80a1\u7968\u5728\u5f00\u76d8\u524d\u5927\u5e45\u8df3\u7a7a\u4e0a\u6da8\uff0c\u6210\u4ea4\u91cf\u5f3a\u52b2\uff0c\u5e76\u4e14\u5728\u4e0a\u5348\u7ee7\u7eed\u671d\u540c\u4e00\u65b9\u5411\u4e0a\u626c\uff0c\u6ca1\u6709\u4e1d\u6beb\u72b9\u8c6b\uff08\u8fd9\u5c31\u662f\u6211\u4eec\u6d4b\u91cf\u6ce2\u52a8\u7387\u548c\u65b9\u5411\u4e00\u81f4\u6027\u7684\u539f\u56e0\uff09\uff0c\u90a3\u4e48\u8fd9\u53ea\u80a1\u7968\u5c31\u5f88\u6709\u53ef\u80fd\u5728\u5f00\u76d8\u540e\u7ee7\u7eed\u4fdd\u6301\u8fd9\u79cd\u8d70\u52bf\u3002\u73b0\u5728\uff0c\u6211\u4eec\u60f3\u77e5\u9053\u6570\u636e\u662f\u5426\u652f\u6301\u8fd9\u4e00\u7406\u8bba\uff0c\u6211\u4eec\u60f3\u77e5\u9053\u8fd9\u4e9b\u80a1\u7968\u6309\u7167\u6211\u4eec\u5047\u8bbe\u7684\u8d70\u52bf\u8fd0\u884c\u7684\u6982\u7387\u3002<\/p>\n\n\n\n<p>\u6211\u4eec\u9700\u8981\u63a2\u7d22\u53d8\u91cf\u548c\u76ee\u6807\u4e4b\u95f4\u7684\u5173\u7cfb\uff0c\u770b\u770b\u5b83\u4eec\u662f\u5426\u771f\u7684\u6709\u5f71\u54cd\uff0c\u66f4\u91cd\u8981\u7684\u662f\uff0c\u6211\u4eec\u4e0d\u4ec5\u8981\u9884\u6d4b\u76ee\u6807\uff0c\u8fd8\u8981\u8861\u91cf\u6211\u4eec\u7684\u9884\u6d4b\u7ed3\u679c\u6709\u591a\u597d\u3002<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>\u83b7\u53d6\u9ad8\u8d28\u91cf\u6570\u636e\u662f\u91cf\u5316\u4ea4\u6613\u6210\u529f\u7684\u5173\u952e<\/strong>\u3002Alpha Vantage \u63d0\u4f9b\u4e86\u4e30\u5bcc\u7684\u80a1\u7968\u6570\u636e\u548c\u5df2\u8ba1\u7b97\u7684\u6307\u6807\uff0c\u662f\u91cf\u5316\u5206\u6790\u7684\u7406\u60f3\u9009\u62e9\u3002<\/li>\n\n\n\n<li><strong>\u4ef7\u683c\u7f3a\u53e3\u548c\u6210\u4ea4\u91cf\u662f\u65e5\u5185\u4ea4\u6613\u51b3\u7b56\u7684\u91cd\u8981\u6307\u6807<\/strong>\u3002\u5b83\u4eec\u53ef\u4ee5\u5e2e\u52a9\u4ea4\u6613\u8005\u8bc6\u522b\u90a3\u4e9b\u5728\u5f00\u76d8\u540e\u53ef\u80fd\u51fa\u73b0\u5927\u5e45\u6ce2\u52a8\u7684\u80a1\u7968\u3002<\/li>\n\n\n\n<li><strong>\u5f00\u76d8\u533a\u95f4\u7a81\u7834\uff08ORB\uff09\u7b56\u7565\u662f\u4e00\u79cd\u6709\u6548\u7684\u65e5\u5185\u4ea4\u6613\u7b56\u7565<\/strong>\u3002\u901a\u8fc7\u5206\u6790\u5f00\u76d8\u533a\u95f4\u7684\u5bbd\u5ea6\u3001\u6ce2\u52a8\u6027\u3001\u6210\u4ea4\u91cf\u548c\u65b9\u5411\u4e00\u81f4\u6027\u7b49\u6307\u6807\uff0c\u53ef\u4ee5\u66f4\u597d\u5730\u9884\u6d4b\u80a1\u7968\u7684\u8d70\u52bf\u3002<\/li>\n\n\n\n<li><strong>\u98ce\u9669\u4e0e\u56de\u62a5\u6bd4\u7387\u662f\u4ea4\u6613\u51b3\u7b56\u7684\u91cd\u8981\u8003\u91cf<\/strong>\u3002\u65e5\u95f4\u4ea4\u6613\u8005\u901a\u5e38\u4f1a\u9009\u62e9 1:3 \u7684\u98ce\u9669\u4e0e\u56de\u62a5\u6bd4\u7387\uff0c\u5e76\u6839\u636e\u5b9e\u9645\u6570\u636e\u7814\u7a76\u6765\u51b3\u5b9a\u4f55\u65f6\u8fdb\u51fa\u5e02\u573a\u3002<\/li>\n<\/ol>\n\n\n\n<p><\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>\u5ef6\u5c55\u9605\u8bfb\u63a8\u8350<\/strong><\/h3>\n\n\n\n<ul class=\"wp-block-list\">\n<li>\u300a<a href=\"https:\/\/www.laoyulaoyu.com\/index.php\/2024\/08\/19\/%e6%89%8b%e6%8a%8a%e6%89%8b%e6%95%99%e4%bd%a0ai%e9%a1%be%e6%8a%95%ef%bc%9a%e5%8f%91%e7%8e%b0%e4%b8%80%e4%b8%aa%e9%ab%98%e8%b4%a8%e9%87%8f%e7%9a%84%e9%87%91%e8%9e%8d%e6%95%b0%e6%8d%ae%e6%ba%90\/\">\u624b\u628a\u624b\u6559\u4f60ai\u987e\u6295\uff1a\u53d1\u73b0\u4e00\u4e2a\u9ad8\u8d28\u91cf\u7684\u91d1\u878d\u6570\u636e\u6e90<\/a>\u300b<\/li>\n\n\n\n<li>\u300a<a href=\"https:\/\/www.laoyulaoyu.com\/index.php\/2024\/09\/24\/2024-%e5%b9%b4%e9%9d%a2%e5%90%91%e7%ae%97%e6%b3%95%e4%ba%a4%e6%98%93%e8%80%85%e7%9a%84%e5%8d%81%e5%a4%a7%e5%bc%80%e6%ba%90-python-%e5%ba%93\/\">2024 \u5e74\u9762\u5411\u7b97\u6cd5\u4ea4\u6613\u8005\u7684\u5341\u5927\u5f00\u6e90 Python \u5e93<\/a>\u300b<\/li>\n\n\n\n<li>\u300a<a href=\"https:\/\/www.laoyulaoyu.com\/index.php\/2024\/10\/02\/%e5%91%8a%e5%88%ab-backtrader%ef%bc%81%e6%8d%a2%e8%bf%99%e4%b8%aa%e5%ba%93%e5%ae%9e%e6%96%bd%e9%87%8f%e5%8c%96%e5%9b%9e%e6%b5%8b\/\">\u544a\u522b backtrader\uff01\u6362\u8fd9\u4e2a\u5e93\u5b9e\u65bd\u91cf\u5316\u56de\u6d4b<\/a>\u300b<\/li>\n\n\n\n<li>\u300a<a href=\"https:\/\/www.laoyulaoyu.com\/index.php\/2024\/09\/26\/%e5%80%9f%e5%8a%a9%e7%ae%97%e6%b3%95%e4%ba%a4%e6%98%93%ef%bc%8c%e7%9c%9f%e7%9a%84%e9%9d%a0%e8%b0%b1%e5%90%97%ef%bc%9f\/\">\u501f\u52a9\u7b97\u6cd5\u4ea4\u6613\uff0c\u771f\u7684\u9760\u8c31\u5417\uff1f<\/a>\u300b<\/li>\n\n\n\n<li>\u300a<a href=\"https:\/\/www.laoyulaoyu.com\/index.php\/2024\/09\/19\/%e6%89%8b%e6%8a%8a%e6%89%8b%e6%95%99%e4%bc%9a%e4%bd%a0%e7%94%a8-ai-%e5%92%8c-python-%e8%bf%9b%e8%a1%8c%e8%82%a1%e7%a5%a8%e4%ba%a4%e6%98%93%e9%a2%84%e6%b5%8b%ef%bc%88%e5%ae%8c%e6%95%b4%e4%bb%a3\/\">\u624b\u628a\u624b\u6559\u4f1a\u4f60\u7528&nbsp;AI \u548c Python \u8fdb\u884c\u80a1\u7968\u4ea4\u6613\u9884\u6d4b\uff08\u5b8c\u6574\u4ee3\u7801\u5e72\u8d27\uff09<\/a>\u300b<\/li>\n<\/ul>\n\n\n\n<p><\/p>\n\n\n\n<p><strong>\u611f\u8c22\u60a8\u9605\u8bfb\u5230\u6700\u540e\u3002\u5982\u679c\u5bf9\u6587\u4e2d\u7684\u5185\u5bb9\u6709\u4efb\u4f55\u7591\u95ee\uff0c\u8bf7\u7ed9\u6211\u7559\u8a00\uff0c\u5fc5\u590d\u3002<\/strong><\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\"\/>\n\n\n\n<p><\/p>\n\n\n\n<p><\/p>\n\n\n\n<p class=\"has-text-align-center\"><strong><mark style=\"background-color:#ffffff\" class=\"has-inline-color has-cyan-bluish-gray-color\">\u672c<\/mark><\/strong><strong><mark style=\"background-color:#ffffff\" class=\"has-inline-color has-cyan-bluish-gray-color\">\u6587\u5185\u5bb9\u4ec5\u4ec5\u662f\u6280\u672f\u63a2\u8ba8\u548c\u5b66\u4e60\uff0c\u5e76\u4e0d\u6784\u6210\u4efb\u4f55\u6295\u8d44\u5efa\u8bae\u3002<\/mark><\/strong><\/p>\n\n\n\n<p class=\"has-text-align-center\"><strong><mark style=\"background-color:#ffffff\" class=\"has-inline-color has-cyan-bluish-gray-color\">\u8f6c\u53d1\u8bf7\u6ce8\u660e\u539f\u4f5c\u8005\u548c\u51fa\u5904\u3002<\/mark><\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4f5c\u8005\uff1a\u8001\u4f59\u635e\u9c7c \u539f\u521b\u4e0d\u6613\uff0c\u8f6c\u8f7d\u8bf7\u6807\u660e\u51fa\u5904\u53ca\u539f\u4f5c\u8005\u3002&#8230;<\/p>\n<div class=\"more-link-wrapper\"><a class=\"more-link\" href=\"https:\/\/laoyulaoyu.com\/index.php\/2024\/10\/30\/%e6%89%8b%e6%8a%8a%e6%89%8b%e6%95%99%e4%bd%a0-ai-%e9%a1%be%e6%8a%95%ef%bc%9a-python-%e5%8a%a9%e5%8a%9b%ef%bc%8c%e8%bd%bb%e6%9d%be%e8%bf%88%e5%85%a5%e7%ae%97%e6%b3%95%e4%ba%a4%e6%98%93%e5%91%98\/\">Continue reading<span class=\"screen-reader-text\">\u624b\u628a\u624b\u6559\u4f60 AI \u987e\u6295\uff1a Python \u52a9\u529b\uff0c\u8f7b\u677e\u8fc8\u5165\u7b97\u6cd5\u4ea4\u6613\u5458\u4e4b\u95e8<\/span><\/a><\/div>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[2],"tags":[3,5],"class_list":{"0":"post-1569","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"hentry","6":"category-aiinvest","7":"tag-ai","9":"entry"},"_links":{"self":[{"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/posts\/1569","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/comments?post=1569"}],"version-history":[{"count":1,"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/posts\/1569\/revisions"}],"predecessor-version":[{"id":1570,"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/posts\/1569\/revisions\/1570"}],"wp:attachment":[{"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/media?parent=1569"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/categories?post=1569"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/laoyulaoyu.com\/index.php\/wp-json\/wp\/v2\/tags?post=1569"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}