mlpack
Functions
preprocess_one_hot_encoding_main.cpp File Reference
#include <mlpack/prereqs.hpp>
#include <mlpack/core/util/io.hpp>
#include <mlpack/core/util/mlpack_main.hpp>
#include <mlpack/core.hpp>
#include <mlpack/core/data/one_hot_encoding.hpp>
Include dependency graph for preprocess_one_hot_encoding_main.cpp:
This graph shows which files directly or indirectly include this file:

Functions

 BINDING_NAME ("One Hot Encoding")
 
 BINDING_SHORT_DESC ("A utility to do one-hot encoding on features of dataset.")
 
 BINDING_LONG_DESC ("This utility takes a dataset and a vector of indices and does one-hot " "encoding of the respective features at those indices. Indices represent " "the IDs of the dimensions to be one-hot encoded." "\" "The output matrix with encoded features may be saved with the "+PRINT_PARAM_STRING("output")+" parameters.")
 
 BINDING_EXAMPLE ("So, a simple example where we want to encode 1st and 3rd feature" " from dataset "+PRINT_DATASET("X")+" into "+PRINT_DATASET("X_output")+" would be" "\"+PRINT_CALL("preprocess_one_hot_encoding", "input", "X", "output", "X_ouput", "dimensions", 1, "dimensions", 3))
 
 BINDING_SEE_ALSO ("@preprocess_binarize", "#preprocess_binarize")
 
 BINDING_SEE_ALSO ("@preprocess_describe", "#preprocess_describe")
 
 BINDING_SEE_ALSO ("@preprocess_imputer", "#preprocess_imputer")
 
 BINDING_SEE_ALSO ("One-hot encoding on Wikipedia", "https://en.m.wikipedia.org/wiki/One-hot")
 
 PARAM_MATRIX_IN_REQ ("input", "Matrix containing data.", "i")
 
 PARAM_MATRIX_OUT ("output", "Matrix to save one-hot encoded features " "data to.", "o")
 
 PARAM_VECTOR_IN_REQ (int, "dimensions", "Index of dimensions that" "need to be one-hot encoded.", "d")
 

Detailed Description

Author
Jeffin Sam

A binding to do one-hot encoding on features from a dataset.

mlpack is free software; you may redistribute it and/or modify it under the terms of the 3-clause BSD license. You should have received a copy of the 3-clause BSD license along with mlpack. If not, see http://www.opensource.org/licenses/BSD-3-Clause for more information.