added header and offset options