code: def test_multi_index_column_assignment_frame(self):
      pdf = pd.DataFrame({"a": [1, 2, 3, 2], "b": [4.0, 2.0, 3.0, 1.0]})
      pdf.columns = pd.MultiIndex.from_tuples([("a", "x"), ("a", "y")])
      psdf = ps.DataFrame(pdf)
  
      psdf["c"] = ps.Series([10, 20, 30, 20])
      pdf["c"] = pd.Series([10, 20, 30, 20])
  
      psdf[("d", "x")] = ps.Series([100, 200, 300, 200], name="1")
      pdf[("d", "x")] = pd.Series([100, 200, 300, 200], name="1")
  
      psdf[("d", "y")] = ps.Series(
          [1000, 2000, 3000, 2000], name=("1", "2")
      )
      pdf[("d", "y")] = pd.Series(
          [1000, 2000, 3000, 2000], name=("1", "2")
      )
  
      psdf["e"] = ps.Series(
          [10000, 20000, 30000, 20000], name=("1", "2", "3")
      )
      pdf["e"] = pd.Series(
          [10000, 20000, 30000, 20000], name=("1", "2", "3")
      )
  
      psdf[[("f", "x"), ("f", "y")]] = ps.DataFrame(
          {
              "1": [100000, 200000, 300000, 200000],
              "2": [1000000, 2000000, 3000000, 2000000],
          }
      )
      pdf[[("f", "x"), ("f", "y")]] = pd.DataFrame(
          {
              "1": [100000, 200000, 300000, 200000],
              "2": [1000000, 2000000, 3000000, 2000000],
          }
      )
  
      self.assert_eq(repr(psdf.sort_index()), repr(pdf))
  
      with self.assertRaisesRegex(
          KeyError, "Key length \\(3\\) exceeds index depth \\(2\\)"
      ):
          psdf[("1", "2", "3")] = ps.Series([100, 200, 300, 200])
  
file_path: spark/python/pyspark/pandas/tests/diff_frames_ops/test_index.py
imports: import pandas
  from pyspark import pandas
  from pyspark.pandas.config import set_option, reset_option
  from pyspark.testing.pandasutils import PandasOnSparkTestCase
  from pyspark.testing.sqlutils import SQLTestUtils
label_desc: Use image node_id 4 for calling the DiffFramesIndexMixin obj's underlying member method code with example usage: obj.test_multi_index_column_assignment_frame() without return types