added functionality to output rmf