format tree