refactoring, added scale