code: def random_orth(dim=3, names=None):
      Z = np.random.standard_normal((3, 3))
      orth = expm(Z - Z.T)
      if not names:
          names = ["e%d" % i for i in range(dim)]
      else:
          if len(names) != dim:
              raise ValueError("len(names) != dim")
      return MG.O(orth, names)
  
file_path: nipy/nipy/core/reference/tests/test_matrix_groups.py
imports: import numpy
  import pytest
  from scipy.linalg import expm
  import nipy.core.reference.tests.matrix_groups
  from nipy.core.api import ArrayCoordMap
label_desc: Use image node_id 3 for calling a global function with example usage: random_orth(dim, names) and returns: MG