code: def imdb(display=False, n_points=None):
      """Return the classic IMDB sentiment analysis training data in a nice package.
  
      Full data is at: http://ai.stanford.edu/~amaas/data/sentiment/aclImdb_v1.tar.gz
      Paper to cite when using the data is: http://www.aclweb.org/anthology/P11-1015
      """
  
      with open(
          cache(github_data_url + "imdb_train.txt"), encoding="utf-8"
      ) as f:
          data = f.readlines()
      y = np.ones(25000, dtype=bool)
      y[:12500] = 0
  
      if n_points is not None:
          data = shap.utils.sample(data, n_points, random_state=0)
          y = shap.utils.sample(y, n_points, random_state=0)
  
      return data, y
  
file_path: shap/shap/datasets.py
imports: import os
  from urllib.request import urlretrieve
  import numpy
  import pandas
  import sklearn.datasets
  import shap
label_desc: Use image node_id 4 for calling a global function with example usage: imdb(display, n_points) and returns: data,  y