From 59110522caa7c5b8fc000ea6101ff139a06fb9ea Mon Sep 17 00:00:00 2001 From: Koichi Akabe Date: Fri, 29 Dec 2023 11:02:27 +0900 Subject: [PATCH] Change missing from 0 to NaN --- src/dmatrix.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dmatrix.rs b/src/dmatrix.rs index 0488e0f..c67a793 100644 --- a/src/dmatrix.rs +++ b/src/dmatrix.rs @@ -112,7 +112,7 @@ impl DMatrix { xgb_call!(xgboost_sys::XGDMatrixCreateFromMat(data.as_ptr(), num_rows as xgboost_sys::bst_ulong, (data.len() / num_rows) as xgboost_sys::bst_ulong, - 0.0, // TODO: can values be missing here? + f32::NAN, &mut handle))?; Ok(DMatrix::new(handle)?) }