IDAX.SPLIT_DATA - Split data into training data and test data
Use this stored procedure to randomly split the input data into two separated subsets, a training data set and a test data set. You can then use the created output tables to build a classification model or a regression model and test its prediction quality.
Note: This feature is available starting from Db2®
version 11.5.4.
Authorization
The privileges held by the authorization ID of the statement must include the IDAX_USER role.
Syntax
IDAX.SPLIT_DATA(in parameter_string varchar(32672))
Parameter descriptions
- parameter_string
- Mandatory one-string parameter that contains pairs of <parameter>=<value> entries that are separated by a comma.
Returned information
FLOAT the number of records in the traintable output table.
Example
CALL IDAX.SPLIT_DATA('intable=CENSUSINCOME, id=ID, traintable=CENSUSINCOME_TRAIN, testtable=CENSUSINCOME_TEST, fraction=0.6, seed=1');
Note: The IDAX.SPLIT_DATA stored procedure is non-deterministic in a MPP
environment, regardless of whether or not the seed parameter is fixed.