initialize the cal with preference