code: def test_iv_transformations_custom(self):
      scale_custom = {"eta1": "y2", "eta2": "y5", "xi1": "x1"}
  
      full_graph, var = self.custom._iv_transformations(
          "xi1", "x2", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "x2")
      self.assertTrue((".x1", "x2") in full_graph.edges())
      self.assertFalse(("xi1", "x2") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "xi1", "y4", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y4")
      self.assertTrue((".x1", "y4") in full_graph.edges())
      self.assertFalse(("xi1", "y4") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "xi1", "y1", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y1")
      self.assertTrue((".x1", "y1") in full_graph.edges())
      self.assertFalse(("xi1", "y1") in full_graph.edges())
      self.assertFalse(("y4", "y1") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "xi1", "eta1", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y2")
      self.assertTrue((".eta1", "y2") in full_graph.edges())
      self.assertTrue((".x1", "y2") in full_graph.edges())
      self.assertFalse(("y1", "eta1") in full_graph.edges())
      self.assertFalse(("xi1", "eta1") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "y1", "eta1", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y2")
      self.assertTrue((".eta1", "y2") in full_graph.edges())
      self.assertTrue((".x1", "y2") in full_graph.edges())
      self.assertFalse(("y1", "eta1") in full_graph.edges())
      self.assertFalse(("xi1", "eta1") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "y1", "eta2", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y5")
      self.assertTrue((".eta2", "y5") in full_graph.edges())
      self.assertFalse(("y1", "eta2") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "y4", "y1", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y1")
      self.assertFalse(("y4", "y1") in full_graph.edges())
  
      full_graph, var = self.custom._iv_transformations(
          "eta1", "y3", scaling_indicators=scale_custom
      )
      self.assertEqual(var, "y3")
      self.assertTrue((".y2", "y3") in full_graph.edges())
      self.assertFalse(("eta1", "y3") in full_graph.edges())
  
imports: import os
  import unittest
  import networkx
  import numpy
  import numpy.testing
  from pgmpy.models import SEM, SEMAlg, SEMGraph
label_desc: Use image node_id 16 for calling the TestSEMGraph obj's underlying member method code with example usage: obj.test_iv_transformations_custom() without return types