code: def test_dimension_selection_bic():
      # Tests whether dimension selection yields correct results
      x1 = [0.6, 0.48, 0.64]
      x2 = [-0.8, 0.48, 0.36]
      x3 = [0.48, 0.64, -0.6]
      x = np.random.randn(200, 3) * 0.1
      x[:40] += x1
      x[40:150] += x2
      x[150:] += x3
      x = (x.T / np.sqrt(np.sum(x**2, 1))).T
  
      precision = 100.0
      my_vmm = select_vmm(list(range(1, 8)), precision, False, x)
      assert my_vmm.k == 3
  
file_path: nipy/nipy/algorithms/clustering/tests/test_vmm.py
imports: from unittest import skipIf
  import numpy
  from nibabel.optpkg import optional_package
  from ..von_mises_fisher_mixture import VonMisesMixture, select_vmm, select_vmm_cv, sphere_density
label_desc: Use image node_id 4 for calling a global function with example usage: test_dimension_selection_bic() without return types