| predict.HGBTRegressor {hana.ml.r} | R Documentation |
Predict using the HGBTRegressor model.
## S3 method for class 'HGBTRegressor' predict(model, data, key, features = NULL, verbose = NULL, thread.ratio = NULL, missing.replacement = NULL, ...)
model |
|
data |
|
key |
|
features |
|
verbose |
|
thread.ratio |
|
missing.replacement |
|
DataFrame
DataFrame containing the prediction result, structured as follows:
ID, INTEGER - ID column, with the same name and type as df's ID column
SCORE, NVARCHAR - representing the predicted values.
CONFIDENCE, DOUBLE - representing the confidence of
a class label assignment.
## Not run:
The trained model can be used for prediction.
Input data for prediction, i.e. with missing target values.
> df_predict$Collect()
ID ATT1 ATT2 ATT3 ATT4
0 1 19.76 6235.0 100.00 100.00
1 2 17.85 46230.0 43.67 84.53
2 3 19.96 7360.0 65.51 81.57
3 4 16.80 28715.0 45.16 93.33
4 5 18.20 21934.0 49.20 83.07
5 6 16.71 1337.0 74.84 94.99
6 7 18.81 17881.0 70.66 92.34
7 8 20.74 2319.0 63.93 95.08
8 9 16.56 18040.0 14.45 61.24
9 10 18.55 1147.0 68.58 97.90
Predict the target values and view the results
> result <- predict(hgr, df_predict, key = 'ID', verbose = FALSE)
> result$Collect()
ID SCORE CONFIDENCE
0 1 23.79109147050638 None
1 2 19.09572889593064 None
2 3 21.56501359501561 None
3 4 18.622664075787082 None
4 5 19.05159916592106 None
5 6 18.815530665858763 None
6 7 19.761714911364443 None
7 8 23.79109147050638 None
8 9 17.84416828725911 None
9 10 19.915574945518465 None
## End(Not run)