final changes for inserting observation