added stats with a flag to sandbox example