complete the r file