Model tweaks

Hi guys, thanks for developing this nice model. Here are some tweaks. 
Nice chatting with you Jarod :)
how about moving all the table updating stuff into a function `updateTable` instead?