add tree with extract example