code: def expected_error_message(display_mode, cut_coords):
      """Return the expected error message depending on display_mode and
      cut_coords. Used in test_invalid_cut_coords_with_display_mode.
      """
      if display_mode == "ortho" or (
          display_mode == "tiled" and cut_coords == 2
      ):
          return (
              f"The input given for display_mode='{display_mode}' needs to "
              "be a list of 3d world coordinates."
          )
      return (
          "The number cut_coords passed does not match the display_mode"
      )
  
imports: import matplotlib.pyplot
  import numpy
  import pytest
  from nibabel import Nifti1Image
  from nilearn.conftest import _affine_mni
  from nilearn.datasets import load_mni152_template
  from nilearn.image import get_data, reorder_img
  from nilearn.plotting import plot_anat, plot_carpet, plot_epi, plot_glass_brain, plot_img, plot_prob_atlas, plot_roi, plot_stat_map
  from nilearn.plotting.img_plotting import MNI152TEMPLATE
label_desc: Use image node_id 9 for calling a global function with example usage: expected_error_message(display_mode, cut_coords) and returns: str, str, display_mode, str