add api to change orderBy and limit of trees

refs #4