title: Create Dummy Variable with Column Transformer using sklearn
body: <p>I've been trying to create a DL model for a practice purpose using ANN. I've a fake bank's customer data in which there are two categorical variable i.e gender and country.</p>
  
  <p>I encode both the columns using <code>LabelEncoder</code> but not able to create dummy variables for country columns. In coutry there are three countries i.e. France, Germany and Spain.</p>
  
  <p>Error I got:</p>
  
  <blockquote>
    <p>ValueError: not enough values to unpack (expected 3, got 2)</p>
  </blockquote>
  
  <p>My Code: </p>
  
  <pre><code># Encodeing categorical data
  # for country column
  labelencoder_X_1 = LabelEncoder()
  X[:, 1] = labelencoder_X_1.fit_transform(X[:, 1])
  
  # for gender column
  labelencoder_X_2 = LabelEncoder()
  X[:, 2] = labelencoder_X_2.fit_transform(X[:, 2])
  
  ct = ColumnTransformer(
  transformers=[
      ("dummy_var",        # Just a name
       OneHotEncoder( # The transformer class
       categories=[[1]])            # The column(s) to be applied on.
       )
  ], remainder='passthrough')
  X = ct.fit_transform(X).toarray()
  X = X[:, 1:]
  # print(X)
  </code></pre>
  
  <p>P.S: I use Pycharm and novice in Deep Learning.</p>
  
  <p>Thanks in Advance!</p>