| 1366 | |
| 1367 | template <class Container> |
| 1368 | inline |
| 1369 | int |
| 1370 | DecisionTree<Container>::encodeIndex(const int &feature_index, |
| 1371 | const int &is_categorical, const int &n_cat_features) const { |
| 1372 | if (is_categorical != 0) { |
| 1373 | return feature_index; |
| 1374 | } else { |
| 1375 | if (feature_index >= 0) { |
| 1376 | return feature_index + n_cat_features; |
| 1377 | } else { |
| 1378 | return feature_index; |
| 1379 | } |
| 1380 | } |
| 1381 | } |
| 1382 | // ------------------------------------------------------------------------- |
| 1383 | |
| 1384 | template <class Container> |
no outgoing calls
no test coverage detected