docstr: Convert a DataFrame of labeled data to a feature matrix in the form
  that ATM can use.
code: def transform(self, data):
      """
      Convert a DataFrame of labeled data to a feature matrix in the form
      that ATM can use.
      """
      if self.class_column in data:
          # pull labels into a separate series and transform them to integers
          labels = np.array(data[[self.class_column]])
          y = self.label_encoder.transform(labels)
          # drop the label column and transform the remaining features
      else:
          y = None
  
      X = data[self.feature_columns]
  
      # one-hot encode the categorical X
      if self.categorical_columns:
          # encode each categorical feature as an integer
          for column, encoder in list(self.column_encoders.items()):
              X[column] = encoder.transform(X[column])
  
          X = self.feature_encoder.transform(X)
  
      else:
          X = X.values
  
      return X, y
  
file_path: ATM/atm/encoder.py
imports: from __future__ import division, unicode_literals
  from builtins import object
  import numpy
  from sklearn.preprocessing import LabelEncoder, OneHotEncoder
label_desc: Use image node_id 3 for calling the DataEncoder obj's underlying member method code with example usage: obj.transform(data) and returns: X,  y