implemented a new storage for factors variables indices