added javadocs and fixed viz bugs