adding initialize function