Final Edits plus Matlab boilerplate code