add scale function to zg2 class