dont use showWarnings=FALSE for write()