This function is called by the disc.ef function in the dprep library.
disc2(x, k)
x
k
Edgar Acuna
disc.ef