class_docstr: FeatureCorrelation visualizer
class_docstr_tok: ["FeatureCorrelation","visualizer"]
docstr: Test selecting feature warning when both index and names are provided
docstr_tok: ["Test","selecting","feature","warning","when","both","index","and","names","are","provided"]
code: def test_feature_correlation_select_feature_by_index_and_name(self):
      """
      Test selecting feature warning when both index and names are provided
      """
      feature_index = [0, 2, 3]
      feature_names = ["age"]
  
      e = (
          "Both feature_index and feature_names are specified. "
          "feature_names is ignored"
      )
      with pytest.raises(YellowbrickWarning, match=e):
          viz = FeatureCorrelation(
              feature_index=feature_index, feature_names=feature_names
          )
          viz.fit(self.X, self.y)
          assert viz.scores_.shape[0] == 3
  
imports: import sys
  import pytest
  import numpy
  import numpy.testing
  from yellowbrick.target import FeatureCorrelation, feature_correlation
  from yellowbrick.exceptions import YellowbrickValueError, YellowbrickWarning
  from sklearn import datasets
  from tests.base import VisualTestCase
label_desc: Use image node_id 10 for calling the TestFeatureCorrelationVisualizer obj's underlying member method code with example usage: obj.test_feature_correlation_select_feature_by_index_and_name() without return types