title: ValueError: X must be a NumPy array
body: <p>I new to python and machine learning. I got an error when trying to implement (decision_regions) plot. 
  I am not sure I understand the problem so I really need help solving this problem. </p>
  
  <p>I think the problem because the target is string maybe I am nor sure. But I do not know how to fix this problem please I need help to fix this </p>
  
  <pre><code> # import arff data using panda
  
  data = arff.loadarff('Run1/Tr.arff') 
  df = pd.DataFrame(data[0]) 
  data =pd.DataFrame(df) 
  data = data.loc[:,'ATT1':'ATT576'] 
  target = df['Class'] 
  target=target.astype(str)
  
  
  #split the data into training and testing 
  data_train, data_test, target_train, target_test = train_test_split(data, target,test_size=0.30, random_state=0) 
  
  
  
   model1 = DecisionTreeClassifier(criterion='entropy', max_depth=1)
  
  num_est = [1, 2, 3, 10] 
  label = ['AdaBoost (n_est=1)', 'AdaBoost (n_est=2)', 'AdaBoost (n_est=3)', 'AdaBoost (n_est=20)']
  
  fig = plt.figure(figsize=(10,8)) 
  gs = gridspec.GridSpec(2,2) 
  grid = itertools.product([0,1],repeat=2)
  
   for n_est, label, grd in zip(num_est, label, grid):   
      boosting = AdaBoostClassifier(base_estimator=model1,n_estimators=n_est)    boosting.fit(data_train,target_train)
  ax = plt.subplot(gs[grd[0], grd[1]])
  fig = plot_decision_regions(data_train , target_train, clf=boosting, legend=2)  
  
  plt.title(label)
  
  plt.show();
  
  ------------------------------------------------------------------ ValueError                                Traceback (most recent call
  &gt; last) &lt;ipython-input-18-646828965d5c&gt; in &lt;module&gt;
  &gt;       7     boosting.fit(data_train,target_train)
  &gt;       8     ax = plt.subplot(gs[grd[0], grd[1]])
  &gt; ----&gt; 9     fig = plot_decision_regions(data_train , target_train, clf=boosting, legend=2)  # clf cannot be change because it's a
  &gt; parameter
  &gt;      10     plt.title(label)
  &gt;      11
  &gt; 
  &gt; /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/mlxtend/plotting/decision_regions.py
  &gt; in plot_decision_regions(X, y, clf, feature_index,
  &gt; filler_feature_values, filler_feature_ranges, ax, X_highlight, res,
  &gt; legend, hide_spines, markers, colors, scatter_kwargs, contourf_kwargs,
  &gt; scatter_highlight_kwargs)
  &gt;     127     """
  &gt;     128 
  &gt; --&gt; 129     check_Xy(X, y, y_int=True)  # Validate X and y arrays
  &gt;     130     dim = X.shape[1]
  &gt;     131 
  &gt; 
  &gt; /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/mlxtend/utils/checking.py
  &gt; in check_Xy(X, y, y_int)
  &gt;      14     # check types
  &gt;      15     if not isinstance(X, np.ndarray):
  &gt; ---&gt; 16         raise ValueError('X must be a NumPy array. Found %s' % type(X))
  &gt;      17     if not isinstance(y, np.ndarray):
  &gt;      18         raise ValueError('y must be a NumPy array. Found %s' % type(y))
  &gt; 
  &gt; ValueError: X must be a NumPy array. Found &lt;class
  &gt; 'pandas.core.frame.DataFrame'&gt;`enter code here`
  </code></pre>