Add pack/unpack method to regression