visualization refactoring