Thanks, Mary. I've been consistently wondering what sample/truncate are doing. Now I got an idea.
Do you know of any way to get the URIs sorted by relevance? Using sample/truncate I can get the 5 most relevant URIs but I don't know which of the 5 is the most relevant one - as far as I understand. Regards, Andreas 2016-09-21 16:31 GMT+02:00 Mary Holstege <mary.holst...@marklogic.com>: > On Wed, 21 Sep 2016 06:34:15 -0700, Andreas Hubmer > <andreas.hub...@ebcont.com> wrote: > > > Hi Erik, > > > > Thanks, cts:value-tuples is a good hint. > > Do you have an idea of how one could get the URIs, sorted by relevance > > (of > > some word query for instance)? > > > > I know what the option "score-logtfidf" does in a cts:search. But what is > > the contribution of "score-logtfidf" in the lexicon functions (cts:uris, > > cts:element-values, ...)? I don't see it. > > It comes into play when you use the sample/truncate options are used to > define what the "first N" means. > > //Mary > > > Regards, > > Andreas > > > > > > > > 2016-09-21 14:25 GMT+02:00 Erik Hennum <erik.hen...@marklogic.com>: > > > >> Hi, Andreas: > >> > >> You can use cts:value-tuples() to form tuples. List the range index for > >> the sort first and the lexicon to be sorted second (for instance, date > >> and > >> then uri): > >> > >> http://docs.marklogic.com/cts:value-tuples > >> > >> Be aware that, if the sorting or sorted values occurs more than once in > >> the document, you'll get a tuple for the cross product over the document > >> (that is, the co-occurrence within the document). > >> > >> The logtfidf score uses the document relevance to the query. > >> > >> > >> Hoping that helps, > >> > >> > >> Erik Hennum > >> > >> > >> ------------------------------ > >> *From:* general-boun...@developer.marklogic.com [ > >> general-boun...@developer.marklogic.com] on behalf of Andreas Hubmer [ > >> andreas.hub...@ebcont.com] > >> *Sent:* Wednesday, September 21, 2016 5:04 AM > >> *To:* MarkLogic Developer Discussion > >> *Subject:* [MarkLogic Dev General] Sorting results of lexicon calls > >> > >> Hi, > >> > >> All the lexicon functions (cts:uris, cts:element-values, ...) support > >> the > >> options "ascending" and "descending" to define the sort order. > >> > >> But sometimes I would like to sort the result of a lexicon call by some > >> other range index. > >> Example: I would like to get the URIs of all documents, ordered by some > >> date element. > >> Can this be done with the lexicon functions? > >> > >> I've seen that all the lexicon functions support the > >> option "score-logtfidf". What is the effect of that option and the other > >> scoring options (in lexicon calls)? I've tried it and I didn't get any > >> different results. > >> > >> Thanks, > >> Andreas > >> > >> -- > >> Andreas Hubmer > >> Senior IT Consultant > >> > >> EBCONT enterprise technologies GmbH > >> Millennium Tower > >> Handelskai 94-96 > >> A-1200 Vienna > >> > >> OUR TEAM IS YOUR SUCCESS > >> > >> UID-Nr. ATU68135644 > >> HG St.Pölten - FN 399978 d > >> > >> _______________________________________________ > >> General mailing list > >> General@developer.marklogic.com > >> Manage your subscription at: > >> http://developer.marklogic.com/mailman/listinfo/general > >> > >> > > > > > > > -- > Using Opera's revolutionary email client: http://www.opera.com/mail/ -- Andreas Hubmer Senior IT Consultant EBCONT enterprise technologies GmbH Millennium Tower Handelskai 94-96 A-1200 Vienna OUR TEAM IS YOUR SUCCESS UID-Nr. ATU68135644 HG St.Pölten - FN 399978 d
_______________________________________________ General mailing list General@developer.marklogic.com Manage your subscription at: http://developer.marklogic.com/mailman/listinfo/general