{"id":71611,"date":"2026-11-17T13:34:21","date_gmt":"2026-11-17T05:34:21","guid":{"rendered":"https:\/\/www.biocloudservice.com\/wordpress\/?p=71611"},"modified":"2026-11-17T13:34:21","modified_gmt":"2026-11-17T05:34:21","slug":"ysx-sc-practice-028-rare-cells-draw-order","status":"publish","type":"post","link":"https:\/\/www.biocloudservice.com\/wordpress\/ysx-sc-practice-028-rare-cells-draw-order\/","title":{"rendered":"\u7a00\u6709\u7ec6\u80de\u5728 UMAP \u4e0a\u770b\u4e0d\u89c1\uff0c\u600e\u4e48\u5224\u65ad\u662f\u6ca1\u6293\u5230\uff0c\u8fd8\u662f\u88ab\u522b\u7684\u70b9\u76d6\u4f4f\u4e86\uff1f"},"content":{"rendered":"<div style=\"max-width:820px;margin:0 auto;color:#263a47;font-size:17px;line-height:1.85;overflow-wrap:break-word\">\n<p>\u75c5\u7406\u540c\u4e8b\u95ee\uff0c\u7b2c\u4e09\u4e2a\u6837\u672c\u91cc\u662f\u4e0d\u662f\u6ca1\u6709\u90a3\u7fa4\u7a00\u6709\u7ec6\u80de\u3002\u4f60\u770b\u4e86\u4e00\u773c\u5408\u5e76 UMAP\uff0c\u6574\u5f20\u56fe\u4e5f\u53ea\u770b\u5230\u4e24\u4e2a\u7ea2\u70b9\uff0c\u6ce8\u91ca\u8868\u5374\u8bf4\u6709\u516d\u9897\u3002\u78b0\u5230\u8fd9\u79cd\u5dee\u522b\uff0c\u53ef\u4ee5\u4e00\u8def\u5012\u67e5\u56db\u4e2a\u6570\uff1a\u539f\u59cb\u6ce8\u91ca\u91cc\u6709\u51e0\u9897\uff0c\u51e0\u9897\u62ff\u5230\u4e86\u8fd9\u5f20\u56fe\u7684\u5750\u6807\uff0c\u591a\u5c11\u548c\u522b\u7684\u70b9\u91cd\u5408\uff0c\u5206\u5230\u6bcf\u4efd\u6837\u672c\u4e2d\u5404\u6709\u51e0\u9897\u3002\u67e5\u5b8c\u4ee5\u540e\uff0c\u201c\u8fd9\u4e00\u4efd\u6837\u672c\u672a\u6807\u51fa\u76ee\u6807\u201d\u548c\u201c\u7ec6\u80de\u5176\u5b9e\u5728\u56fe\u91cc\uff0c\u53ea\u662f\u88ab\u522b\u7684\u70b9\u906e\u4f4f\u201d\u5c31\u6709\u4e86\u5404\u81ea\u5bf9\u5e94\u7684\u8bc1\u636e\u3002<\/p>\n<p><img data-recalc-dims=\"1\" loading=\"lazy\" decoding=\"async\" width=\"1240\" height=\"800\" style=\"width:100%;height:auto;display:block;border-radius:12px\" alt=\"\u56fa\u5b9a\u5750\u6807\u5148\u6570\u51fa\u516d\u9897\u7a00\u6709\u7ec6\u80de\uff0c\u518d\u7528\u76ee\u6807\u540e\u753b\u548c\u5206\u6837\u672c\u5448\u73b0\u627e\u56de\u88ab\u76d6\u4f4f\u7684\u70b9\" src=\"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2026\/11\/ysx-sc-practice-028-rare-cells-draw-order.png?resize=1240%2C800&#038;ssl=1\" \/><\/p>\n<p><a download style=\"display:inline-block;margin:3px;padding:4px 10px;border:1px solid #bad0dd;border-radius:5px\" href=\"https:\/\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2026\/11\/ysx-sc-practice-028-rare-cells-draw-order.zip\">\u4e0b\u8f7d\u5b8c\u6574\u4ee3\u7801\u3001\u793a\u4f8b\u6570\u636e\u4e0e\u53c2\u8003\u8f93\u51fa\uff08ZIP\uff09<\/a> \u00b7 <a download style=\"display:inline-block;margin:3px;padding:4px 10px;border:1px solid #bad0dd;border-radius:5px\" href=\"https:\/\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2026\/11\/ysx-sc-practice-028-rare-cells-draw-order.pdf\">\u4e0b\u8f7d\u56fe\u6587\u64cd\u4f5c\u624b\u518c\uff08PDF\uff09<\/a><\/p>\n<h2>\u5148\u4fdd\u7559\u4e24\u5f20\u72ec\u7acb\u8f93\u5165\u8868<\/h2>\n<p>\u7b2c\u4e00\u5f20\u662f\u4f5c\u56fe\u524d\u7684\u5b8c\u6574\u6ce8\u91ca\uff0c\u4e00\u884c\u4e00\u4e2a\u6761\u7801\uff0c\u5305\u542b\u6837\u672c\u548c\u7c7b\u522b\u3002\u7b2c\u4e8c\u5f20\u662f\u8fd9\u5e45\u56fe\u5b9e\u9645\u4f7f\u7528\u7684\u4e8c\u7ef4\u5750\u6807\u3002\u8fd9\u91cc\u72ec\u7acb\u4fdd\u5b58\u5f88\u91cd\u8981\u3002\u6709\u7684\u4eba\u4f1a\u5148\u628a\u6240\u6709\u7f3a\u5c11\u5750\u6807\u7684\u6ce8\u91ca\u884c\u5220\u6389\uff0c\u518d\u95ee\u6709\u591a\u5c11\u76ee\u6807\u6ca1\u753b\u4e0a\u53bb\u3002\u6b64\u65f6\u5206\u6bcd\u5df2\u7ecf\u53d8\u5c0f\uff0c\u65e0\u6cd5\u56de\u6eaf\u9057\u6f0f\u3002\u793a\u4f8b\u7684\u6807\u7b7e\u8868\u523b\u610f\u91c7\u7528\u4e0d\u540c\u7684\u884c\u987a\u5e8f\uff0c\u4ee3\u7801\u4ee5\u6761\u7801\u8fde\u63a5\uff0c\u8981\u6c42\u6bcf\u4e2a\u5750\u6807\u90fd\u80fd\u627e\u5230\u660e\u786e\u6807\u7b7e\uff0c\u540c\u65f6\u4fdd\u7559\u90a3\u4e9b\u5728\u5b8c\u6574\u6ce8\u91ca\u91cc\u6709\u8bb0\u5f55\u5374\u6ca1\u6709\u5750\u6807\u7684\u6761\u7801\u3002\u5b9e\u9645\u9879\u76ee\u7ecf\u5e38\u4f1a\u9047\u5230\u591a\u4e2a\u6837\u672c\u91cd\u590d\u4f7f\u7528\u76f8\u540c\u7684\u6db2\u6ef4\u6761\u7801\uff0c\u5e94\u5148\u628a\u6355\u83b7\u6279\u6b21\u52a0\u5165\u952e\u503c\u3002<\/p>\n<p>\u8fd9\u7ec4\u6559\u5b66\u6570\u636e\u5305\u62ec\u4e09\u4e2a\u6837\u672c\uff0c\u5404\u6709\u516d\u5341\u9897\u975e\u76ee\u6807\u7ec6\u80de\u3002\u7b2c\u4e00\u4efd\u53e6\u6709\u56db\u9897\u76ee\u6807\u7ec6\u80de\uff0c\u7b2c\u4e8c\u4efd\u53e6\u6709\u4e24\u9897\uff0c\u7b2c\u4e09\u4efd\u6ca1\u6709\u76ee\u6807\u6807\u7b7e\u3002\u4e24\u4e2a\u8868\u4e2d\u7684\u4e00\u767e\u516b\u5341\u516d\u9897\u7ec6\u80de\u5168\u90e8\u53ef\u4ee5\u5bf9\u9f50\uff0c\u6211\u4eec\u6709\u610f\u7ed9\u56db\u9897\u76ee\u6807\u70b9\u4e0e\u67d0\u4e2a\u80cc\u666f\u70b9\u5b8c\u5168\u4e00\u6837\u7684\u5750\u6807\uff0c\u53e6\u5916\u4e24\u9897\u7684\u4f4d\u7f6e\u5219\u80fd\u533a\u5206\u3002\u8fd9\u6837\u7684\u8bbe\u8ba1\u8ba9\u8bfb\u8005\u80fd\u4eb2\u624b\u6838\u5b9e\u906e\u76d6\u7684\u539f\u56e0\u3002\u771f\u5b9e\u6570\u636e\u4e2d\u7cbe\u786e\u5750\u6807\u91cd\u590d\u4e0d\u4e00\u5b9a\u5e38\u89c1\uff0c\u663e\u793a\u5668\u6216\u5370\u5237\u4e0a\u7684\u4e24\u4e2a\u70b9\u5373\u4f7f\u4e2d\u5fc3\u6ca1\u6709\u91cd\u5408\uff0c\u53ea\u8981\u70b9\u5f84\u8db3\u591f\u5927\uff0c\u4e5f\u53ef\u80fd\u51fa\u73b0\u8fd1\u4f3c\u906e\u6321\uff0c\u4e24\u79cd\u73b0\u8c61\u8981\u7528\u4e0d\u540c\u65b9\u5f0f\u68c0\u67e5\u3002<\/p>\n<pre style=\"max-width:100%;overflow:auto;padding:14px;box-sizing:border-box;background:#f1f6fa;line-height:1.6;font-size:0.9em\"><code class=\"language-sh\">python -m pip install -r requirements.txt\npython run.py --input example --out results\n<\/code><\/pre>\n<h2>\u6838\u5bf9\u6ce8\u91ca\u3001\u5750\u6807\u548c\u6837\u672c\u4e09\u4e2a\u5206\u6bcd<\/h2>\n<p>\u5148\u770b sample_counts.tsv\u3002\u7b2c\u4e00\u4efd\u6837\u672c\u5728\u5b8c\u6574\u6ce8\u91ca\u91cc\u6709\u56db\u4e2a\u76ee\u6807\uff0c\u8fdb\u5165\u56fe\u7684\u4e5f\u662f\u56db\u4e2a\uff0c\u5206\u6bcd\u516d\u5341\u56db\u3002\u7b2c\u4e8c\u4efd\u662f\u516d\u5341\u4e8c\u9897\u4e2d\u7684\u4e24\u9897\u3002\u7b2c\u4e09\u4efd\u6709\u516d\u5341\u9897\u975e\u76ee\u6807\uff0c\u96f6\u9897\u76ee\u6807\uff0c\u800c\u4e14\u516d\u5341\u9897\u90fd\u6709\u5750\u6807\u3002\u8fd9\u610f\u5473\u7740\u5728\u672c\u6b21\u53ef\u7528\u6570\u636e\u548c\u5f53\u524d\u6ce8\u91ca\u89c4\u5219\u4e0b\uff0c\u7b2c\u4e09\u4efd\u6ca1\u6709\u88ab\u6807\u6210\u76ee\u6807\u7684\u7ec6\u80de\u3002\u5982\u679c\u8981\u5199\u6210\u7ec4\u7ec7\u5185\u771f\u6b63\u7f3a\u4e4f\u8fd9\u79cd\u7ec6\u80de\uff0c\u8fd8\u5e94\u6838\u67e5\u53d6\u6837\u533a\u57df\u3001\u76ee\u6807\u6ce8\u91ca\u7684\u95e8\u69db\u3001\u7ec4\u7ec7\u89e3\u79bb\u548c\u6355\u83b7\u7387\uff0c\u4ee5\u53ca\u8fd9\u4e9b\u7ec6\u80de\u6709\u6ca1\u6709\u5728\u8d28\u91cf\u8fc7\u6ee4\u65f6\u88ab\u4e22\u6389\u3002\u7528\u6237\u770b\u5230\u7684\u6570\u636e\u8868\u53ef\u4ee5\u652f\u6301\u201c\u672c\u6b21\u672a\u68c0\u51fa\u201d\u7684\u8868\u8ff0\uff0c\u81f3\u4e8e\u603b\u4f53\u4e30\u5ea6\u9700\u53e6\u6709\u91cd\u590d\u4e0e\u8bbe\u8ba1\u3002<\/p>\n<p>\u7136\u540e\u770b missing_coordinates.tsv\u3002\u7ec3\u4e60\u91cc\u5b83\u53ea\u6709\u8868\u5934\uff0c\u8bf4\u660e\u5df2\u6807\u6ce8\u7684\u7ec6\u80de\u5168\u90e8\u6709\u5750\u6807\u3002\u73b0\u5728\u81ea\u5df1\u5236\u9020\u4e00\u4e2a\u771f\u7f3a\u56fe\u7684\u4f8b\u5b50\uff1a\u590d\u5236\u6574\u4e2a example \u6587\u4ef6\u5939\uff0c\u4fdd\u7559 labels.tsv \u4e0d\u52a8\uff0c\u4ec5\u5728\u526f\u672c\u7684 coordinates.tsv \u4e2d\u53bb\u6389 D1_R01 \u90a3\u4e00\u884c\uff0c\u6307\u5b9a\u65b0\u7684\u8f93\u5165\u548c\u8f93\u51fa\u76ee\u5f55\u3002\u7b2c\u4e00\u4efd\u6837\u672c\u7684\u6ce8\u91ca\u76ee\u6807\u4ecd\u6709\u56db\u9897\uff0c\u80fd\u7ed8\u5236\u7684\u76ee\u6807\u4f1a\u53d8\u6210\u4e09\u9897\uff0c\u7f3a\u5931\u8868\u4f1a\u76f4\u63a5\u5217\u51fa\u90a3\u4e2a\u6761\u7801\u3002\u53ea\u6539\u6563\u70b9\u5927\u5c0f\u6216\u628a\u7ea2\u8272\u8c03\u4eae\uff0c\u90fd\u65e0\u6cd5\u628a\u4e00\u4e2a\u7f3a\u5750\u6807\u7684\u7ec6\u80de\u753b\u56de\u6765\u3002\u8fd9\u4e2a\u7ec3\u4e60\u4e5f\u80fd\u68c0\u67e5\u81ea\u5df1\u7684\u7ed8\u56fe\u6d41\u7a0b\u662f\u5426\u5728\u5408\u5e76\u8868\u683c\u65f6\u9759\u9ed8\u6254\u6389\u4e86\u8bb0\u5f55\u3002<\/p>\n<h2>\u4ece\u4e00\u4e2a\u88ab\u906e\u4f4f\u7684\u6761\u7801\u67e5\u5230\u5b83\u7684\u80cc\u666f\u70b9<\/h2>\n<p>\u6253\u5f00 target_overlap.tsv\uff0c\u6311\u51fa D1_R03\u3002\u6309\u5408\u5e76\u9762\u677f\u770b\uff0c\u5b83\u548c\u4e00\u4e2a\u80cc\u666f\u70b9\u7684\u4e2d\u5fc3\u5750\u6807\u5b8c\u5168\u76f8\u540c\uff0c\u800c\u4e14\u80cc\u666f\u70b9\u5728\u8f93\u5165\u987a\u5e8f\u4e2d\u6392\u5f97\u66f4\u665a\u3002\u82e5\u4f7f\u7528\u76f8\u540c\u7684\u5b9e\u5fc3\u70b9\u5f62\u3001\u76f8\u540c\u9762\u79ef\u5e76\u6309\u7167\u8f93\u5165\u5148\u540e\u7ed8\u5236\uff0c\u8f83\u665a\u7684\u70b9\u5c31\u4f1a\u76d6\u4f4f\u8f83\u65e9\u7684\u70b9\u3002\u811a\u672c\u5148\u7528\u7a7a\u95f4\u7d22\u5f15\u67e5\u4e00\u4e2a\u5c40\u90e8\u5706\u5f62\u8303\u56f4\u5185\u7684\u80cc\u666f\uff0c\u518d\u5728\u8fd9\u4e2a\u5c0f\u8303\u56f4\u91cc\u5206\u522b\u6570\u7cbe\u786e\u540c\u5750\u6807\u7684\u80cc\u666f\uff0c\u4ee5\u53ca\u6bd4\u76ee\u6807\u66f4\u665a\u7ed8\u5236\u7684\u80cc\u666f\u3002\u6709\u4e86\u6761\u7801\u548c\u5750\u6807\uff0c\u8fd8\u53ef\u4ee5\u5230\u539f\u59cb\u5750\u6807\u8868\u6309\u53cc\u5217\u7cbe\u786e\u67e5\u8be2\uff0c\u627e\u51fa\u4e0e\u5b83\u91cd\u5408\u7684\u53e6\u4e00\u4e2a\u7ec6\u80de\u3002<\/p>\n<pre style=\"max-width:100%;overflow:auto;padding:14px;box-sizing:border-box;background:#f1f6fa;line-height:1.6;font-size:0.9em\"><code class=\"language-python\">def overlap(indices, points, target, radius):\n    background = indices[~target[indices]]\n    if not len(background):\n        return [(i, 0, 0, 0) for i in indices[target[indices]]]\n    tree = cKDTree(points[background])\n    audit = []\n    for i in indices[target[indices]]:\n        near = background[tree.query_ball_point(points[i], radius)]\n        same = near[np.all(points[near] == points[i], axis=1)]\n        audit.append((i, len(same), int((same &gt; i).sum()), len(near)))\n    return audit\n<\/code><\/pre>\n<p>\u8fd9\u91cc\u7684\u8fd1\u90bb\u534a\u5f84\u53d6\u96f6\u70b9\u4e00\u4e8c\u4e2a\u5750\u6807\u5355\u4f4d\u3002\u8fd9\u4e2a\u7126\u70b9\u5728\u5408\u5e76\u56fe\u7684\u8303\u56f4\u5185\u6709\u4e94\u4e2a\u80cc\u666f\u90bb\u70b9\uff0c\u53ea\u4fdd\u7559\u672c\u6837\u672c\u540e\u662f\u56db\u4e2a\uff0c\u8bf4\u660e\u6709\u4e00\u9897\u63a5\u8fd1\u7684\u80cc\u666f\u7ec6\u80de\u6765\u81ea\u522b\u7684\u6837\u672c\u3002\u534a\u5f84\u5185\u7684\u4e94\u9897\u4e0d\u7b49\u4e8e\u5c4f\u5e55\u4e0a\u4e00\u5b9a\u6321\u4f4f\u5b83\u7684\u4e94\u9897\u3002\u70b9\u9762\u79ef\u901a\u5e38\u7528\u663e\u793a\u5355\u4f4d\u8bbe\u5b9a\uff0c\u5177\u4f53\u906e\u6321\u8fd8\u4f9d\u8d56\u56fe\u7247\u5bbd\u9ad8\u3001\u5750\u6807\u8f74\u8303\u56f4\u3001\u900f\u660e\u5ea6\u548c\u8f93\u51fa\u5206\u8fa8\u7387\u3002\u7cbe\u786e\u91cd\u5408\u53ef\u4ee5\u4ece\u5750\u6807\u76f4\u63a5\u786e\u8ba4\uff1b\u5bf9\u4e8e\u8ddd\u79bb\u5f88\u8fd1\u5374\u4e0d\u76f8\u540c\u7684\u70b9\uff0c\u5e94\u8be5\u540c\u65f6\u770b\u5b9e\u9645\u5bfc\u51fa\u7684\u56fe\uff0c\u5fc5\u8981\u65f6\u5728\u56fa\u5b9a\u5c3a\u5bf8\u7684\u5c40\u90e8\u7a97\u53e3\u653e\u5927\u5e76\u6807\u6ce8\u6761\u7801\u3002<\/p>\n<div style=\"overflow:auto\">\n<table style=\"width:100%;border-collapse:collapse\">\n<thead>\n<tr>\n<th style=\"padding:9px;text-align:left;background:#ffebc5\">\u6838\u5bf9\u5230\u7684\u60c5\u51b5<\/th>\n<th style=\"padding:9px;text-align:left;background:#ffebc5\">\u7ec3\u4e60\u4e2d\u7684\u4f4d\u7f6e<\/th>\n<th style=\"padding:9px;text-align:left;background:#ffebc5\">\u5408\u9002\u7684\u4e0b\u4e00\u6b65<\/th>\n<\/tr>\n<\/thead>\n<tbody>\n<tr>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u6ce8\u91ca\u6709\u76ee\u6807\uff0c\u5750\u6807\u6709\u76ee\u6807\uff0c\u540e\u753b\u80cc\u666f\u540c\u4f4d\u7f6e<\/td>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">D1_R01 \u7b49\u56db\u9897<\/td>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u56fa\u5b9a\u5750\u6807\uff0c\u8ba9\u76ee\u6807\u6700\u540e\u7ed8\u5236<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u6ce8\u91ca\u6709\u76ee\u6807\uff0c\u5750\u6807\u6587\u4ef6\u6f0f\u4e86\u6761\u7801<\/td>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u624b\u5de5\u79fb\u9664 D1_R01 \u7684\u526f\u672c<\/td>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u5bf9\u7167\u8f93\u5165\u53ca\u5bf9\u8c61\u5b50\u96c6\uff0c\u67e5\u51fa\u6f0f\u5728\u54ea\u4e00\u6b65<\/td>\n<\/tr>\n<tr>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u6ce8\u91ca\u548c\u7ed8\u56fe\u5747\u4e3a\u96f6\u76ee\u6807<\/td>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">D3 \u7684\u516d\u5341\u9897\u7ec6\u80de<\/td>\n<td style=\"padding:9px;vertical-align:top;border-bottom:1px solid #d6e0e7\">\u56de\u5230\u8868\u8fbe\u3001\u8d28\u63a7\u548c\u53d6\u6837\u8bb0\u5f55\u67e5\u8986\u76d6<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div>\n<h2>\u540c\u4e00\u5957\u5750\u6807\u753b\u4e24\u6b21\uff0c\u518d\u6309\u6837\u672c\u5206\u9762<\/h2>\n<p>\u73b0\u5728\u6253\u5f00 order_comparison.png\u3002\u5de6\u56fe\u6309\u8f93\u5165\u884c\u5e8f\u753b\u6240\u6709\u70b9\uff0c\u53f3\u56fe\u5206\u4e24\u5c42\uff0c\u5148\u753b\u6de1\u8272\u80cc\u666f\uff0c\u518d\u7528\u9192\u76ee\u989c\u8272\u7ed8\u5236\u76ee\u6807\u3002\u4e24\u5e45\u56fe\u4f7f\u7528\u540c\u4e00\u5f20\u5750\u6807\u8868\u3001\u76f8\u540c\u70b9\u9762\u79ef\u548c\u76f8\u540c\u5750\u6807\u8303\u56f4\u3002\u7b2c\u4e8c\u79cd\u753b\u6cd5\u80fd\u8ba9\u76ee\u6807\u770b\u89c1\uff0c\u4ecd\u7136\u4fdd\u7559\u5b83\u539f\u6765\u7684\u4f4d\u7f6e\u548c\u5468\u56f4\u7684\u7ec6\u80de\u5bc6\u5ea6\u3002\u6539\u53d8\u968f\u673a\u79cd\u5b50\u6216\u91cd\u65b0\u62df\u5408 UMAP \u53ef\u80fd\u8ba9\u7ea2\u70b9\u8dd1\u5230\u522b\u7684\u533a\u57df\uff0c\u53cd\u800c\u5f88\u96be\u518d\u9a8c\u8bc1\u521a\u624d\u90a3\u56db\u9897\u7a76\u7adf\u5982\u4f55\u88ab\u76d6\u4f4f\u3002\u4e0b\u8f7d\u5305\u4e2d\u7684\u7ed8\u56fe\u51fd\u6570\u5982\u4e0b\u3002<a href=\"https:\/\/matplotlib.org\/stable\/gallery\/misc\/zorder_demo.html\">Matplotlib \u7684\u56fe\u5c42\u987a\u5e8f\u793a\u4f8b<\/a><\/p>\n<pre style=\"max-width:100%;overflow:auto;padding:14px;box-sizing:border-box;background:#f1f6fa;line-height:1.6;font-size:0.9em\"><code class=\"language-python\">def draw(ax, indices, points, target, size, front):\n    if front:\n        base = indices[~target[indices]]\n        focus = indices[target[indices]]\n        ax.scatter(*points[base].T, s=size, color=&quot;#BCD5DF&quot;, edgecolors=&quot;none&quot;, zorder=1)\n        ax.scatter(*points[focus].T, s=size, color=&quot;#D64C34&quot;, edgecolor=&quot;#70251D&quot;, linewidth=.35, zorder=2)\n    else:\n        colors = np.where(target[indices], &quot;#D64C34&quot;, &quot;#BCD5DF&quot;)\n        ax.scatter(*points[indices].T, s=size, color=colors, edgecolors=&quot;none&quot;)\n    ax.set(aspect=&quot;equal&quot;, xlabel=&quot;UMAP 1&quot;, ylabel=&quot;UMAP 2&quot;)\n<\/code><\/pre>\n<p>\u53e6\u4e00\u4e2a\u8f93\u51fa sample_panels.png \u4f7f\u7528\u540c\u4e00\u5168\u5c40\u5750\u6807\uff0c\u5c06\u6837\u672c\u5206\u522b\u653e\u5230\u4e09\u4e2a\u9762\u677f\u3002\u56fe\u9898\u76f4\u63a5\u5199\u76ee\u6807\u6570\u91cf\u548c\u8be5\u9762\u677f\u5185\u7684\u603b\u7ec6\u80de\u6570\uff0c\u6bcf\u4e2a\u9762\u677f\u4fdd\u7559\u76f8\u540c\u7684\u6a2a\u7eb5\u8f74\u8303\u56f4\u3002\u5982\u679c\u6bcf\u4e2a\u9762\u677f\u90fd\u72ec\u7acb\u62c9\u4f38\u5230\u586b\u6ee1\u753b\u5e03\uff0c\u5206\u5e03\u72ed\u7a84\u7684\u4e00\u4e2a\u6837\u672c\u770b\u4e0a\u53bb\u53ef\u80fd\u548c\u5e7f\u6cdb\u5206\u6563\u7684\u6837\u672c\u4e00\u6837\u5bbd\u3002\u82e5\u4e3a\u6bcf\u4e2a\u6837\u672c\u91cd\u65b0\u8bad\u7ec3 UMAP\uff0c\u5750\u6807\u4e5f\u4e0d\u518d\u5904\u4e8e\u540c\u4e00\u4e2a\u53c2\u8003\u7cfb\uff0c\u8bfb\u8005\u4e0d\u80fd\u628a\u4e24\u4e2a\u56fe\u7684\u5de6\u4e0a\u89d2\u7b80\u5355\u89c6\u4f5c\u540c\u4e00\u7247\u7ec6\u80de\u72b6\u6001\u3002\u5df2\u7ecf\u4f7f\u7528 Seurat \u7684\u8bfb\u8005\uff0c\u53ef\u4ee5\u5728\u540c\u4e00 reduction \u4e0a\u7ed3\u5408\u9ad8\u4eae\u3001\u7ed8\u5236\u987a\u5e8f\u548c\u6309\u6837\u672c\u62c6\u5206\uff0c\u6700\u540e\u4ecd\u5e94\u4ece\u6761\u7801\u8868\u6838\u5bf9\u6570\u91cf\u3002<a href=\"https:\/\/satijalab.org\/seurat\/reference\/dimplot\">Seurat DimPlot \u7684\u53c2\u6570\u8bf4\u660e<\/a><\/p>\n<p>\u5982\u679c\u522b\u4eba\u4ea4\u7ed9\u4f60\u7684\u662f\u7ecf\u8fc7\u56db\u820d\u4e94\u5165\u7684\u5750\u6807\u8868\uff0c\u5148\u8be2\u95ee\u539f\u6765\u7684\u7cbe\u5ea6\u3002\u4e24\u4e2a\u5728\u539f\u56fe\u91cc\u7a0d\u6709\u504f\u79bb\u7684\u6761\u7801\uff0c\u5bfc\u51fa\u5230\u5c0f\u6570\u70b9\u540e\u4e00\u4f4d\u540e\u53ef\u80fd\u88ab\u8bb0\u6210\u5b8c\u5168\u76f8\u540c\u3002\u5206\u522b\u7528\u539f\u59cb\u7cbe\u5ea6\u548c\u62a5\u544a\u7cbe\u5ea6\u7edf\u8ba1\u91cd\u5408\u6570\uff0c\u82e5\u53ea\u6709\u540e\u8005\u660e\u663e\u589e\u52a0\uff0c\u5e94\u628a\u8fd9\u79cd\u5dee\u5f02\u5f52\u5230\u5bfc\u51fa\u8fc7\u7a0b\uff0c\u5e76\u56de\u5230\u539f\u59cb\u5bf9\u8c61\u53d6\u5f97\u5750\u6807\u518d\u786e\u8ba4\u906e\u6321\u3002<\/p>\n<h2>\u628a\u201c\u770b\u89c1\u51e0\u4e2a\u7ea2\u70b9\u201d\u8fd8\u539f\u6210\u53ef\u91cd\u590d\u7684\u8ba1\u6570<\/h2>\n<p>\u628a\u4e09\u4f4d\u6837\u672c\u7684\u76ee\u6807\u6570\u5199\u5728\u56fe\u6ce8\u91cc\uff0c\u6bd4\u5728\u56fe\u4e0a\u6570\u7ea2\u8272\u6591\u5757\u66f4\u53ef\u9760\u3002\u82e5\u4e24\u9897\u76ee\u6807\u7ec6\u80de\u5f7c\u6b64\u4e5f\u5b8c\u5168\u91cd\u5408\uff0c\u5373\u4fbf\u628a\u76ee\u6807\u5c42\u653e\u5728\u6700\u4e0a\u9762\uff0c\u8089\u773c\u4ecd\u53ea\u770b\u5230\u4e00\u4e2a\u7ea2\u70b9\u3002\u672c\u4f8b\u91cd\u70b9\u662f\u76ee\u6807\u4e0e\u80cc\u666f\u7684\u906e\u76d6\uff0c\u81ea\u5df1\u7684\u6570\u636e\u53ef\u4ee5\u53e6\u5916\u628a\u76ee\u6807\u70b9\u6309\u5750\u6807\u5206\u7ec4\uff0c\u5217\u51fa\u540c\u4f4d\u7f6e\u7684\u591a\u4e2a\u76ee\u6807\u6761\u7801\u3002\u4e5f\u4e0d\u8981\u4e3a\u4e86\u8ba9\u70b9\u770b\u5f97\u591a\uff0c\u7ed9\u6bcf\u4e2a\u76ee\u6807\u968f\u610f\u52a0\u968f\u673a\u6296\u52a8\u5374\u4e0d\u6ce8\u660e\uff1b\u8fd9\u4f1a\u8ba9\u8bfb\u8005\u8bef\u4ee5\u4e3a\u5b83\u4eec\u7684\u6295\u5f71\u4f4d\u7f6e\u786e\u5b9e\u4e0d\u540c\u3002\u9700\u8981\u5c55\u793a\u6570\u91cf\u65f6\uff0c\u53ef\u4ee5\u5728\u5c40\u90e8\u653e\u5927\u56fe\u65c1\u9644\u4e00\u4e2a\u6761\u7801\u6570\uff0c\u65e2\u4fdd\u7559\u539f\u5750\u6807\uff0c\u53c8\u628a\u539f\u6765\u7684\u7ec6\u80de\u5206\u6bcd\u8bf4\u6e05\u695a\u3002<\/p>\n<p>\u8fd8\u6709\u4e00\u79cd\u5e38\u89c1\u8bef\u4f1a\u6765\u81ea\u62bd\u6837\u3002\u82e5\u80cc\u666f\u6709\u51e0\u5341\u4e07\u9897\u7ec6\u80de\uff0c\u7ed8\u56fe\u8f6f\u4ef6\u53ef\u80fd\u53ea\u9009\u4e00\u90e8\u5206\u7528\u4e8e\u4ea4\u4e92\u9884\u89c8\uff0c\u622a\u56fe\u4e2d\u7684\u5bc6\u5ea6\u5c31\u4e0d\u518d\u662f\u5168\u91cf\u8986\u76d6\u3002\u53ef\u4ee5\u5bf9\u975e\u76ee\u6807\u6309\u6837\u672c\u56fa\u5b9a\u79cd\u5b50\u62bd\u6837\uff0c\u540c\u65f6\u4fdd\u7559\u6240\u6709\u5df2\u6807\u6ce8\u76ee\u6807\uff0c\u5e76\u5728\u56fe\u6ce8\u660e\u786e\u80cc\u666f\u62bd\u6837\u65b9\u5f0f\u548c\u539f\u603b\u6570\u3002\u8fd9\u6837\u9002\u5408\u68c0\u67e5\u76ee\u6807\u4f4d\u4e8e\u54ea\u4e9b\u533a\u57df\uff0c\u4f46\u56fe\u4e2d\u7ea2\u70b9\u5360\u663e\u793a\u70b9\u6570\u7684\u6bd4\u4f8b\u4e0d\u80fd\u5f53\u4f5c\u4f30\u8ba1\u4e30\u5ea6\u3002\u771f\u6b63\u7684\u7ec4\u6210\u6bd4\u8f83\u4ecd\u8981\u5728\u6bcf\u4efd\u6837\u672c\u7684\u5b8c\u6574\u6ce8\u91ca\u8868\u8ba1\u7b97\uff0c\u7136\u540e\u4ee5\u6837\u672c\u4e3a\u5355\u4f4d\u8ba8\u8bba\u53d8\u5316\u3002<\/p>\n<p>\u4ea4\u4ed8\u56fe\u7247\u65f6\u628a\u5750\u6807\u8868\u3001\u6761\u7801\u8ba1\u6570\u3001\u8986\u76d6\u6392\u67e5\u8868\u968f\u56fe\u4fdd\u5b58\uff0c\u8bb0\u4e0b\u56fe\u5c42\u987a\u5e8f\u4e0e\u8f93\u51fa\u5c3a\u5bf8\u3002\u5408\u4f5c\u8005\u82e5\u95ee\u54ea\u4e00\u4e2a\u6837\u672c\u786e\u5b9e\u6ca1\u770b\u5230\uff0c\u65e2\u6709\u5b8c\u6574\u6ce8\u91ca\u548c\u7ec6\u80de\u6570\u4f5c\u7b54\uff0c\u4e5f\u53ef\u4ee5\u5b9a\u4f4d\u90a3\u4e9b\u80fd\u88ab\u9ad8\u4eae\u627e\u56de\u7684\u6761\u7801\u3002\u5927\u961f\u5217\u6309\u6837\u672c\u6e32\u67d3\u9ad8\u6e05\u56fe\u65f6\uff0c\u53ef\u5148\u8bb0\u5f55\u5355\u5f20\u5bfc\u51fa\u548c\u6574\u5957\u6279\u91cf\u56fe\u7684\u5185\u5b58\u4e0e\u65f6\u95f4\uff0c\u518d\u636e\u6b64\u9009\u62e9\u662f\u5426\u9700\u8981<a href=\"https:\/\/www.biocloudservice.com\/wordpress\/compute-services\/\">\u4e91\u751f\u4fe1\u79d1\u7814\u670d\u52a1\u5668\u79df\u8d41<\/a>\u3002<\/p>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>\u5728\u56fa\u5b9a UMAP \u5750\u6807\u4e0a\u5148\u6570\u6761\u7801\u3001\u6838\u5bf9\u76ee\u6807\u662f\u5426\u6709\u5750\u6807\uff0c\u518d\u9ad8\u4eae\u5e76\u5206\u6837\u672c\u7ed8\u56fe\uff0c\u533a\u5206\u6ca1\u6709\u6807\u6ce8\u3001\u6ca1\u6709\u8fdb\u5165\u56fe\u548c\u70b9\u88ab\u8986\u76d6\u3002<\/p>\n","protected":false},"author":1,"featured_media":71608,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_post_was_ever_published":false},"categories":[71],"tags":[],"class_list":["post-71611","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-single-cell"],"jetpack_sharing_enabled":true,"jetpack_featured_media_url":"https:\/\/i0.wp.com\/www.biocloudservice.com\/wordpress\/wp-content\/uploads\/2026\/11\/ysx-sc-practice-028-rare-cells-draw-order.png?fit=1240%2C800&ssl=1","_links":{"self":[{"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/posts\/71611","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/comments?post=71611"}],"version-history":[{"count":1,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/posts\/71611\/revisions"}],"predecessor-version":[{"id":73671,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/posts\/71611\/revisions\/73671"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/media\/71608"}],"wp:attachment":[{"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/media?parent=71611"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/categories?post=71611"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.biocloudservice.com\/wordpress\/wp-json\/wp\/v2\/tags?post=71611"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}