Introduction - If you have any usage issues, please Google them yourself
Maximum Likelihood (ML) criteria and maximum a posteriori (MAP) criterion, Code, there are very complete notes and explanations Including script files and function files in the form.