; selects the 'chapter' children of the context node that have one or ; more 'title' children ; ; Abbreviated XPath: chapter[title] ; Full XPath: child::chapter[child::title] (define tree '(text (chapter (title "Introduction")) (chapter "No title for this chapter") (chapter (title "Conclusion"))) ) ; Low-level: ((node-reduce (select-kids (ntype?? 'chapter)) (sxml:filter (select-kids (ntype?? 'title)))) tree) ; SXPath: ((sxpath `((chapter (title)))) tree) ==> ((chapter (title "Introduction")) (chapter (title "Conclusion")))