How do reference operators really work?

MJ. Smith
MJ. Smith MVP Posts: 55,539
edited November 2024 in English Forum

From the Wiki:

Using Operators with References

With most datatypes, you can also search for ranges, as the bible example above shows. But if you want more control over the range, you can also change the operator (the equals sign). The following operators are available (listed in order, from the most exact at the top to the broadest at the bottom):

Operator Description Example search John 3:16 John 3:16-17 John 3:17-20 John 3:10-20 John 3:16-4:10
= The exact value <bible = Jn 3:16-17> Yes
subset Any reference wholly included in the search value <bible subset Jn 3:16-17> Yes Yes
superset Any reference that includes the whole search value <bible superset Jn 3:16-17> Yes Yes Yes
~ An intersection with the search value that doesn’t cross chapter boundaries <bible ~ Jn 3:16-17> Yes Yes Yes Yes
intersect Any intersection with the search value <bible intersect Jn 3:16-17> Yes Yes Yes Yes Yes

=======================

From the Help file:


Some data types allow for references to be matched with varying levels of exactness. This is specified by an optional data type matching operator, either = or . Each data type uses these operators differently, but in general:
  •      <DataTypeName = reference> — match the specified reference precisely
  •      <DataTypeName ~ reference> — match the specified reference loosely or generously
  •      <DatatypeName reference> — let the software decide how loose or precise the matching is

=========================

The Help file has fewer options than the Wiki ... and I know the Wiki options work as described. What are some examples of Datatypes that work differently so I can guess what "match loosely" means? Fuzzy searches I understand but ...

And "let the software decide" implies defaults ... any place where the defaults are documented?

Orthodox Bishop Alfeyev: "To be a theologian means to have experience of a personal encounter with God through prayer and worship."; Orthodox proverb: "We know where the Church is, we do not know where it is not."

Comments

  • Dave Hooton
    Dave Hooton MVP Posts: 36,339

    MJ. Smith said:

    •      <DataTypeName ~ reference> — match the specified reference loosely or generously

    We know this has a more precise definition for the Bible datatype. Other datatypes are similar  e.g.

         <JustinMartyr ~ Justin Martyr, Dialogue with Trypho 8>   will find "Justin Martyr, Dialogue with Trypho 2-8"; whereas

         <JustinMartyr = Justin Martyr, Dialogue with Trypho 8> is exact (the manuscript might have 8.4 but the underlying assignment has to match)

        <LogosMorphGr>  only works with ~  e.g. <LogosMorphGr = N?P??> gives zero results because of the wildcard ?

    MJ. Smith said:

      •      <DatatypeName reference> — let the software decide how loose or precise the matching is

    I think the general interpretation/default is  ~  or  "loose"; as opposed to "precise" e.g.

        <JustinMartyr Justin Martyr, Dialogue with Trypho 8>   defaults to <JustinMartyr ~ Justin Martyr, Dialogue with Trypho 8> 

        <LogosMorphGr N?P??> defaults to <LogosMorphGr ~ N?P??>

    There are many datatypes but the "Help" description could definitely be more precise!

    Dave
    ===

    Windows 11 & Android 13

  • MJ. Smith
    MJ. Smith MVP Posts: 55,539

    Orthodox Bishop Alfeyev: "To be a theologian means to have experience of a personal encounter with God through prayer and worship."; Orthodox proverb: "We know where the Church is, we do not know where it is not."

  • Ross Strader
    Ross Strader Member Posts: 156 ✭✭

    Dave and MJ, 

    I was glad to find this post today. I was working on a search and am not able to make it work. The example from the wiki perfectly fit my needs, but I'm missing something. 

    From the Wiki on Search Help near the bottom in the Logos Now section:

    Intertext

    Intertext (Intertextuality) labels expose the data behind the interactive resource “New Testament Use of the Old Testament”.

    • {Label Intertext WHERE [NOT] Source=~BibleReference1}
    • {Label Intertext WHERE [NOT] Target=~BibleReference2}
    • {Label Intertext WHERE [NOT] Relationship=~Citation | Quotation | Allusion | Echo}
    • {Label Intertext WHERE [NOT] Corpus=~New Testament | ... |} —> not strictly needed as the only Corpus is the NT.

    For example:
       {Label Intertext WHERE Source<Gen-Mal>} —> finds passages in the NT whose Source is the OT
       {Label Intertext WHERE Target<Mt-Rev>} —> finds passages in the OT that are used in the NT
       {Label Intertext WHERE Source<Gen-Deut> AND Relationship=Quotation} —> finds quotations in the NT that come from Gen-Deut.
       {Speaker <Person Jesus>} WITHIN {Label Intertext WHERE Source<Gen-Mal>} —> finds passages from the OT that were used by Jesus
       {Speaker <Person Moses>} WITHIN {Label Intertext WHERE Target<Mt-Jn>} —> finds OT passages spoken by Moses that were used in the Gospels
       {Speaker <Person Moses>} WITHIN {Label Intertext} —> finds Intertext passages in both OT & NT where the speaker is Moses

    I am not able to achieve any results from these Intertext searches. 

    Have you had success?

  • MJ. Smith
    MJ. Smith MVP Posts: 55,539

    I believe this particular label is a Logos Now feature.

    Orthodox Bishop Alfeyev: "To be a theologian means to have experience of a personal encounter with God through prayer and worship."; Orthodox proverb: "We know where the Church is, we do not know where it is not."

  • Ross Strader
    Ross Strader Member Posts: 156 ✭✭

    I wonder if anyone with Logos Now is able to run this kind of search with success? 

    I will post it in that forum as well. 

    Thank you!

  • MJ. Smith
    MJ. Smith MVP Posts: 55,539

    Orthodox Bishop Alfeyev: "To be a theologian means to have experience of a personal encounter with God through prayer and worship."; Orthodox proverb: "We know where the Church is, we do not know where it is not."

  • Louis St. Hilaire
    Louis St. Hilaire Member, Logos Employee Posts: 513

    MJ. Smith said:

    The Help file has fewer options than the Wiki ... and I know the Wiki options work as described. What are some examples of Datatypes that work differently so I can guess what "match loosely" means? Fuzzy searches I understand but ...

    And "let the software decide" implies defaults ... any place where the defaults are documented?

    Maybe there are some obscure exceptions that I'm unaware of, but, I think, in practice, no operator defaults to the tilde, and Bible data types are the only case where the tilde is actually distinct from intersect.

  • MJ. Smith
    MJ. Smith MVP Posts: 55,539

    Orthodox Bishop Alfeyev: "To be a theologian means to have experience of a personal encounter with God through prayer and worship."; Orthodox proverb: "We know where the Church is, we do not know where it is not."

  • Dave Hooton
    Dave Hooton MVP Posts: 36,339

    For example:
       {Label Intertext WHERE Source<Gen-Mal>} —> finds passages in the NT whose Source is the OT
       {Label Intertext WHERE Target<Mt-Rev>} —> finds passages in the OT that are used in the NT
       {Label Intertext WHERE Source<Gen-Deut> AND Relationship=Quotation} —> finds quotations in the NT that come from Gen-Deut.
       {Speaker <Person Jesus>} WITHIN {Label Intertext WHERE Source<Gen-Mal>} —> finds passages from the OT that were used by Jesus
       {Speaker <Person Moses>} WITHIN {Label Intertext WHERE Target<Mt-Jn>} —> finds OT passages spoken by Moses that were used in the Gospels
       {Speaker <Person Moses>} WITHIN {Label Intertext} —> finds Intertext passages in both OT & NT where the speaker is Moses

        

    I am not able to achieve any results from these Intertext searches. 

    I fixed a formatting error with the use of tilde  ~ in the wiki, so the examples are now displaying correctly e.g.

       {Label Intertext WHERE Source ~ <Gen-Mal>} —> finds passages in the NT whose Source is the OT
       {Label Intertext WHERE Target ~ <Mt-Rev>} —> finds passages in the OT that are used in the NT
       {Label Intertext WHERE Source ~ <Gen-Deut> AND Relationship=Quotation} —> finds quotations in the NT that come from Gen-Deut.

    Dave
    ===

    Windows 11 & Android 13