code: def make_diagonal(x):
      """Converts a vector into an diagonal matrix"""
      m = np.zeros((len(x), len(x)))
      for i in range(len(m[0])):
          m[i, i] = x[i]
      return m
  
file_path: ML-From-Scratch/mlfromscratch/utils/data_manipulation.py
imports: from __future__ import division
  from itertools import combinations_with_replacement
  import numpy
  import math
  import sys
label_desc: Use image node_id 12 for calling a global function with example usage: make_diagonal(x) and returns: m