prepare.output function

Output constructor