A Brief Guide to Patty, a VT100 Interface to Pat
Pat, the software to which Patty is an interface, is a powerful search tool for on-line texts. For example, it allows one to search for words, parts of words, and phrases, to combine searches in various ways, to perform proximity searches, to limit searches to a work, author, or century, and then to view the results first as a Key Word In Context (KWIC) concordance and then in a variety of fuller contexts. The majority of examples in this guide are drawn from the Oxford English Dictionary or our Modern English Texts Database.
This document explains the menu choices offered by Patty, with brief notes and examples. The highlighted characters on the screen are "hot keys" -- there is no need to hit the return key after one has typed a "hot key" letter.
Patty shares its nomenclature with PatMotif, the X Windows graphical interface to Pat. PatMotif is available in the Electronic Text Center and on X Windows terminals around the Grounds.
A copy of this document is available on-line as part of the Library's Electronic Text Service. For more information, contact the Electronic Text Center, Alderman Library: 434-924-3230.
The following three choices allows the user to override the software's default settings.
- Set Proximity Threshold: Allows you to set the number of characters for proximity searches (e.g. word x near word y). The default is 80 characters. Type in the number of characters you would like for the new proximity value, and hit return. Although there will be no on-screen message to tell you so, the proximity value has now changed, and it will remain at your specified setting for the rest of your search session, or until it is reset. See also Proximity (below).
- Set Left Context: Allows you to set the number of characters shown to the left of the search result (the default is 14), in the View screen.
- Set Surround Size: Allows you to set the number of characters displayed when the viewing option Surrounding Text chosen. The default setting is 600 characters.
Pat Access: Allows you to bypass the Patty interface and to access Pat directly. A Pat manual is available in the Electronic Text Center. Not all Pat commands can be used through Pat Access, but this feature can be of use as a means to speed up certain types of search. For example, the Combine command in Patty (see below) can only add together two terms at once; Pat Access can be used to combine and search for multiple terms -- to combine, say, four variant spellings of "love" (and every word that begins with "love", you can use Pat Access to search for "love + loue + loving + louing". Unlike the search feature in Patty, Pat Access insists that search terms longer than one word (or one word searches that include a space at the end) be enclosed in quotation marks. Note that if you wish to exit Pat Access without performing any operation, you need to use Ctrl-C to exit.
Quit: Allows you to quit out of Patty altogether.
Hit the hot key S, type in the word(s) you wish to find, and hit return. Typing "light" will find all words that begin with the characters "l-i-g-h-t" (light, lightening, lighter, etc); adding a space after the word will limit the search only to "light".
The Search feature allows you to search all texts within a particular database (e.g. Modern English Texts), a group of texts (all texts by Austen) or all of a single text (Emma) to which you have previously Constrained searches (See Constrain, under Structure, below).
This choice allows you to view the results of a search first in a Key Word In Context (KWIC) form, and then to display the search term in some larger context. Upon choosing View, you will first be asked to select First Few or Sample:
First Few: Gives you the first 19 instances of the word for which you have searched. Move the arrow cursor to the search you wish to see sampled and select First Few.
Sample: Gives you an evenly distributed sample of 19 of the instances of the word or phrase for which you have searched. For example, in a typical display, the result set will be divided by 19 and every 19th result will be listed. Sample is particularly useful for searches that produce a large number of results. If your search has resulted in fewer than 19 occurrences, this option gives you all examples. As with First Few, Sample requires the arrow cursor to be on the search you wish to view.
The example below shows what you would see if you viewed a search on the phrase "academical village" in Modern English Texts:
==>1 JefLett222 ..le" title="AN ACADEMICAL VILLAGE" recipient="Hugh
2 JefLett222 ..8100506"> "AN ACADEMICAL VILLAGE" <lb> <i>To Messrs
3 JefLett223 ..e in fact, an academical village, instead of a large
4 JefLett497 .. too, of our academical village, </page></seg><seg>
Note that the left hand column of the View screen gives an abbreviation and a reference number to the work being quoted (in the example above the four references are all from Jefferson's Letters -- designated as "JefLett"). These abbreviations are sometimes cryptic; to find out what each one means, you can search the bibliography under the Help choice.
Display One: Allows you to view one of the numbered results in a context larger than the KWIC display. These contexts vary, depending on the database you are searching; in Modern English Texts, for example, the choices are:
Surrounding Text: gives the search term in the context of 600 characters.
Page: gives the search term in the context of one page (if you choose this for a work that is unpaginated, you will get the next larger context that is tagged: chapter, scene, poem, etc.
Larger context: for most prose, this will be chapter, letter, speech; for poetry, the whole poem; for drama, the scene or act.
Work: Allows you to view a whole work. The system can take a while to bring back the text of a whole work.
Citation: provides bibliographic information from the file's header.
Other databases may have additional choices, such as Entry and Lookup in the OED. Some databases may also have Surrounding Text as a choice, which displays your search term in a default context of 600 characters, unless you have previously set the value to a different size (see Set Surround Size, under File, above). You will be asked for the number of the example you would like to see in larger context.
The text viewer through which one displays the texts is a rather basic software tool. Among other things, however, it allows the following:
move forward one screen: type f (or hit the space bar) move back one screen: type b search forward (case sensitive): type / and then the word or phrase search back (case sensitive): type ? and then the word or phrase
Back: takes one back to the initial (top level) menu without viewing a result.
Add: Adds the results of two searches together to produce a combined result, e.g. "love" in Austen's Pride and Prejudice plus "love" in Austen's Emma. To achieve this, one needs to search first for "love" within Pride and Prejudice and within Emma (see Structure, below). Type the number of the first search you would like and hit return; type the number of the second search you would like and hit return again.
Subtract: Subtracts one search from another, e.g. "love" in Austen's collected works minus "love" in Austen's Emma, to get the times that Austen uses love outside Emma. To achieve this, one needs to search first for "love" within Austen's works (see Structure, below), and then "love" within Emma. Once these two searches have been completed, type in the search number of the larger set and hit return; then type in the search number of the smaller set and hit return.
Intersect: Finds the point of commonality between two sets, e.g. those quotations in the Oxford English Dictionary dated 1591, intersected with those by Shakespeare, to give those quotations dated 1591 and by Shakespeare.
Note that you will be looking for intersecting sets, not intersecting words -- you cannot intersect 1591 and Shakespeare because the string "1591" does not occur within the string "Shakespeare". Read Structure, below, before attempting to follow these Intersect commands.
To intersect, first search the OED for Shakespeare (using the abbreviation Shak), then ask for Shak within Author:
Then ask for the Entry field Including the "shak within Author" search:
Structure Including Last
1 shak 41733 matches 2 1 within docs "A" 33305 matches 3 docs "E" incl 2 14067 matches
This gives you your first set. For the second set, search for 1591 within Date, and then Entry including "1591 within Date", following the same procedure as above (substituting "D" for "A"):
Which doc struct:: D
Structure Including Last
4 1591 5561 matches 5 4 within docs "D" 5328 matches 6 docs "E" incl 5 4469 matches
Finally, type Combine, then Intersect; enter the number of the first set, and then the number of the second set.
7 #3 ^ #6 2412 matches
Range: Allows you to search for a range of letters or numbers. Useful for creating concordances (a range of words within a database between cab and cad) and lists of dates (all the quotations in the OED between 1550 and 1575). The latter can be achieved by defining the range of numbers and then, as a separate operation (under Structure), asking for that range within the "date" document structure.
Note that these searches can often take several seconds.
Last Within: Allows one to look at the last search within the context of a particular document structure (author, work, etc). E.g., search the Modern English Texts database for "love", choose Structure, then Last Within, and when prompted for a "Document" put in the name of an author: Austen. This will now provide you with all the times your previous search term (love) occurs within the works of Jane Austen:
1 "love" 17112 matches 2 #1 within docs "Austen" 982 matches
From this pair of searches we know how many times words beginning with "love" appear in the Modern English Texts database, and how many times they appear within Austen's works therein.
Another example: Poe within the document structure Author in the Oxford English Dictionary yields occurrences of Poe as an author of quotations. (Be warned that the OED uses inconsistent abbreviations for other authors, such as Shakespeare):
1 poe 41846 matches 2 1 within docs "A" 453 matches
Here you know the number of times the three-character string "poe" appears in the OED, and then the number of times this three-character string appears within the pair of tags that mark off an author's name: <author>poe</author>.
Struct Incl Last: Allows you to find the number of times a particular document structure includes the last search you performed:
1 "love" 17112 matches 2 docs "Austen" including #1 8 matches
From this pair of searches we know how many times "love" appears in the entire Modern English Texts database, and how many documents by Jane Austen in that database contain the word "love".
1 poe 41846 matches 2 docs "A" Including 1 453 matches
Here you know the number of times the three-character string "poe" appears in the OED, and then the number of times the tagset used to mark off an author's name -- <author> </author> -- includes the three-character string "poe". "Poe within <AUTHOR>" will be the same number as "AUTHOR including Poe"; "love within Austen" will vary wildly from "Austen including love" because the former count is the times "love" occurs within the works of Jane Austen, while the latter count refers to the number of works by Austen that include "love".
Within: Similar to Last Within except that instead of focusing on the last search, one may choose any previous search.
Struct Incl: Similar to Struct Incl Last, except that instead of focusing on the last search, one may choose any previous search.
Constrain: Allows one to constrain to a particular search or document structure. [For a step-by-step example of this type of search, see "Examples of two common types of search" under A Quick Guide to Searching the Electronic Library]
Last Result: Allows one to choose the last search or operation.
# (previous result): Allows one to choose a result within a previously performed search.
Document: Enter a "text ID" such as AusEmma (found in the Modern English Texts database list) or a document structure (such as D for date, found under Document Structures in the OED).
Unconstrain: Removes a previous constraint.
Note that unless you have reset the proximity value (see Set Proximity Threshold, under Control Panel, under File, above), "proximity" means "within 80 characters".
Near: Finds one word or result near another.
One use for this is in Latin texts, where word order may not be predictable. Searching for amor vincit omnia in the Patrologia Latina Database may yield nothing; searching for amo near vinc, then that set near omn, may provide at least a related result:
"Amor impenetrabilis est lorica, respuit jacula, gladios excutit, periculis insultat, mortem ridet, si amor est, vinci: omnia."
Followed By: Finds one word or result followed by another.
Not Near: Finds one word or result not near another.
Not Followed By: Finds one word or result not followed by another.
An example of several proximity searches working in conjunction: Suppose you are attempting to prove that when Shelley wrote "If winter comes, can spring be far behind?" he was not the first writer to make use of the image of winter being followed by spring. You could simply search for spring Near winter, but this would produce a set of results which would also include listings of all four seasons, as well as occurances of spring being followed by winter, which would not be the metaphor of renewal for which you were looking. To save yourself hours of reading through useless results, you would need to limit the extent of your search, like so:
First, Search for "winter" and "spring," and also "summer" and "autumn."
Second, search for winter Not N_e_ar summer, and winter Not N_e_ar autumn. You should then have six sets of results displayed: the four searches for the names of the seasons, and the two searches using the Not N_e_ar command.
Third, use the Intersect command on the two last searches to find the set of occurances of the word winter which are neither within eighty characters of the word summer nor within eighty characters of the word autumn. To do this, select Combine, then Intersect, then give the numbers of your two Not N_e_ar searches.
Fourth, now that you have a set of "winter" occurances isolated from unwanted words, you can use the Followed By command to establish the number of occurances of "spring" following an isolated "winter." Patty will prompt you for the two set numbers.
Search Help: A Brief Guide to Patty, a VT100 Interface to Pat (this document on-line)
Bibliography: the list of works for a database
Tags Used: the list of SGML tags used in a database (knowledge of these can be useful when constructing searches.
Example Searches: step-by-step examples of basic searches
Allows you to quit the searching session altogether.