code: def test_remove_highly_correlated_features():
      correlated_df = pd.DataFrame(
          {
              "id": [0, 1, 2, 3],
              "diff_ints": [34, 11, 29, 91],
              "words": [
                  "test",
                  "this is a short sentence",
                  "foo bar",
                  "baz",
              ],
              "corr_words": [4, 24, 7, 3],
              "corr_1": [99, 88, 77, 33],
              "corr_2": [99, 88, 77, 33],
          },
      )
  
      es = EntitySet(
          "data",
          {
              "correlated": (
                  correlated_df,
                  "id",
                  None,
                  {"words": NaturalLanguage},
              )
          },
      )
      fm, _ = dfs(
          entityset=es,
          target_dataframe_name="correlated",
          trans_primitives=["num_characters"],
          max_depth=1,
      )
  
      with pytest.raises(
          ValueError,
          match="pct_corr_threshold must be a float between 0 and 1, inclusive.",
      ):
          remove_highly_correlated_features(fm, pct_corr_threshold=1.1)
  
      with pytest.raises(
          ValueError,
          match="pct_corr_threshold must be a float between 0 and 1, inclusive.",
      ):
          remove_highly_correlated_features(fm, pct_corr_threshold=-0.1)
  
      with pytest.raises(
          AssertionError,
          match="feature named not_a_feature is not in feature matrix",
      ):
          remove_highly_correlated_features(
              fm, features_to_check=["not_a_feature"]
          )
  
      to_check = remove_highly_correlated_features(
          fm,
          features_to_check=[
              "corr_words",
              "NUM_CHARACTERS(words)",
              "diff_ints",
          ],
      )
      to_check_columns = set(to_check.columns)
      assert len(to_check_columns) == 4
      assert "NUM_CHARACTERS(words)" not in to_check_columns
      assert "corr_1" in to_check_columns
      assert "corr_2" in to_check_columns
  
      to_keep = remove_highly_correlated_features(
          fm,
          features_to_keep=["NUM_CHARACTERS(words)"],
      )
      to_keep_names = set(to_keep.columns)
      assert len(to_keep_names) == 4
      assert "corr_words" in to_keep_names
      assert "NUM_CHARACTERS(words)" in to_keep_names
      assert "corr_2" not in to_keep_names
  
      new_fm = remove_highly_correlated_features(fm)
      assert len(new_fm.columns) == 3
      assert "corr_2" not in new_fm.columns
      assert "NUM_CHARACTERS(words)" not in new_fm.columns
  
      diff_threshold = remove_highly_correlated_features(
          fm, pct_corr_threshold=0.8
      )
      diff_threshold_cols = diff_threshold.columns
      assert len(diff_threshold_cols) == 2
      assert "corr_words" in diff_threshold_cols
      assert "diff_ints" in diff_threshold_cols
  
file_path: featuretools/featuretools/tests/selection/test_selection.py
imports: import numpy
  import pandas
  import pytest
  from woodwork.column_schema import ColumnSchema
  from woodwork.logical_types import Boolean, BooleanNullable, NaturalLanguage
  from featuretools import EntitySet, Feature, dfs
  from featuretools.selection import remove_highly_correlated_features, remove_highly_null_features, remove_low_information_features, remove_single_value_features
  from featuretools.tests.testing_utils import make_ecommerce_entityset
label_desc: Use image node_id 7 for calling a global function with example usage: test_remove_highly_correlated_features() without return types