fix library error on reduced.r