Choosing the right estimator — scikit-learn 1.2.0 documentationを元にMermaidでまとめた。
flowchart TD A((Start))--> B{50サンプル以上?} B -->|Yes| B1{カテゴリの\n予測?} B -->|No| B2((データを収集)) B1 -->|Yes| C1{正解ラベルあり?} C1 -->|Yes| Z3((分類)):::terminal C1 -->|No| Z4((クラスタリング)):::terminal B1 -->|No| C2{数量の予測?} C2 -->|Yes| Z1((回帰)):::terminal C2 -->|No| H((次元削除)):::terminal classDef terminal fill:#69F
分類
flowchart TD Z3((分類)):::terminal --> I1{10万サンプル以下?} I1 -->|Yes| I11[線形SVC] I1 -->|No| I21[SDG Classifier]:::method I21 -->|うまくいかない| I22[kernel approximation\nGBDT]:::method I11 -->|うまくいかない| I12{テキストデータ?} I12 -->|Yes| I122[ネイティブベイズ]:::method I12 -->|No| I13[K近傍法]:::method I13 -->|うまくいかない| I131[SVC\nランダムフォレスト]:::method classDef terminal fill:#69F classDef method fill:#f9f,stroke:#333,stroke-width:4px
クラスタリング
flowchart TD Z4((クラスタリング)):::terminal --> J1{カテゴリ数は既知?} J1 -->|Yes| J11{<10万サンプル以下?} J11 -->|Yes| J12[KMeans]:::method J12 -->|うまくいかない| J13[スペクトラルクラスタリング\nGMM]:::method J11 -->|No| J21[MiniBatch\nKMeans]:::method J1 -->|No| J3{<10K samples} J3 -->|Yes| J31[MeanShift\nVGBMM]:::method J3 -->|No| J34((不運)) classDef terminal fill:#69F classDef method fill:#f9f,stroke:#333,stroke-width:4px
回帰
flowchart TD Z1((回帰)):::terminal --> D1{10万サンプル以下?} D1 -->|No| E1[SGD回帰分析]:::method D1 -->|Yes| E2{説明変数xの一部が重要?} E2 -->|Yes| F1[Lasso\nElasticNet]:::method E2 -->|No| F2[Ridge\n線形SVR]:::method F2 -->|うまくいかない| F3[SVR Kernel='rbf'\nEnsembleRegressors]:::method classDef terminal fill:#69F classDef method fill:#f9f,stroke:#333,stroke-width:4px
次元削除
flowchart TD Z((次元削除)):::terminal --> H[Randomized PCA]:::method H -->|うまくいかない| H11{10万サンプル以下?} H11 -->|Yes| H22[Isomap\nSpectral Embedding]:::method H11 -->|No| H3[kernel\napproximation]:::method H22 -->|うまくいかない| H4[LLE]:::method classDef terminal fill:#69F classDef method fill:#f9f,stroke:#333,stroke-width:4px