AI::XGBoost::DMatrix - XGBoost class for data
version 0.11
use aliased 'AI::XGBoost::DMatrix'; my $train_data = DMatrix->FromFile(filename => 'agaricus.txt.train');
XGBoost DMatrix perl model
Work In Progress, the API may change. Comments and suggestions are welcome!
Construct a DMatrix from diferent sources. Based on parameters dispatch to the correct From* method
Refer to From* to see what can be done.
Construct a DMatrix from a file
File to read
Supress messages
Construct a DMatrix from a bidimensional array
Bidimensional array
Array with the labels of the rows of matrix. Optional
Value to identify missing values. Optional, default `NaN`
Set float type property
Field name of the information
array with the information
Piddle with the information
Get float type property
Set uint type property
Get uint type property
Save DMatrix object as a binary file.
This file should be used with FromFile
Filename and path
Don't show information messages, optional, default 1
Set label of DMatrix. This label is the "classes" in classification problems
Array with the labels
Piddle with the labels
Get label of DMatrix. This label is the "classes" in classification problems
Set weight of each instance
Array with the weights
pdl with the weights
Get the weight of each instance
Set base margin of booster to start from
Array with the margins
Get the base margin
Set group size
Array with the size of each group
Number of rows
Number of columns
Dimensions of the matrix. That is: rows, columns
Slice the DMatrix and return a new DMatrix tha only contains the list of indices
Reference to an array of indices
Free the DMatrix
This method gets called automatically
Pablo Rodríguez González <pablo.rodriguez.gonzalez@gmail.com>
Copyright (c) 2017 by Pablo Rodríguez González.
To install AI::XGBoost, copy and paste the appropriate command in to your terminal.
cpanm
cpanm AI::XGBoost
CPAN shell
perl -MCPAN -e shell install AI::XGBoost
For more information on module installation, please visit the detailed CPAN module installation guide.