3 types: linear <quantize.m>, tangent <quantize_tan.m>, arctangent <quantize_atan.m>
The quantization algorithms take in a signal, and various parameters. One parameter tells how many chunks to break the signal into. Each chunk might be quantized differently depending on the maxx paramenter. The maxx parameter is the maximum magnitude of any element in the signal. If this is given, then the signal is quantized between -maxx, and maxx. If maxx is zero, then a separate maxx is calculated for every chunk of the signal, thus giving better resolution per chunk at the price of an extra 16-bit number per chunk. And, of course, the number of bits to use per sample is given.
Technical detail: Since we are not actually making small files to transmit, the signal is unquantized right away so that we can play it back. Information is lost.
Also, the 3 files have a wrapper file <general_quantize.m> for ease of use.