XQuery for Humanists (Coding for Humanists)
Book information
Description
XQuery is the best language for querying, manipulating, and transforming XML and JSON documents. Because XML is in many ways the lingua franca of the digital humanities, learning XQuery empowers humanists to discover and analyze their data in new ways. Until now, though, XQuery has been difficult to learn because there was no textbook designed for non- or beginner programmers. XQuery for Humanists fills this void with an approachable guidebook aimed directly at digital humanists. Clifford B. Anderson and Joseph C. Wicentowski introduce XQuery in terms accessible to humanities scholars and do not presuppose any prior background in programming. It provides an informed, opinionated overview and recommends the best implementations, libraries, and paradigms to empower those who need it most. Emphasizing practical applicability, the authors go beyond the XQuery language to include the basics of underlying standards like XPath, related standards like XQuery Full Text and XQuery Update, and explain the difference between XQuery and languages like Python and R. This book will afford readers the skills they need to build and analyze large-scale documentary corpora in XML. XQuery for Humanists is immeasurably valuable to instructors of digital humanities and library science courses alike and likewise is a ready reference for faculty, graduate students, and librarians who seek to master XQuery for their projects. Cover Title Copyright Dedication Contents Introduction Chapter 1: Why XQuery for Humanists? 1.1 Built for the Kind of Data Most Digital Humanists Use 1.2 Easy for Beginning Programmers to Learn 1.3 XML and Digital Humanities Data 1.3.1 XML Compared to Other Formats 1.3.1.1 JSON 1.3.1.2 RDF 1.4 XQuery Compared to XSLT 1.5 A Great Digital Humanities Community 1.6 Questions Chapter 2: Setting Up Your XQuery Environment 2.1 Installing Java 2.2 Setting Up BaseX 2.3 Setting Up eXist 2.4 Setting Up oXygen 2.5 Setting Up Saxon 2.6 Accessing Online Companion Materials 2.7 Preserving and Sharing Code with GitHub 2.8 Questions and Exercises Chapter 3: Reviewing XML and Related Standards 3.1 History and Goals of XML 3.2 XML Basics 3.2.1 Writing Well-Formed XML 3.2.2 Writing Valid XML 3.3 XML as a Data Standard 3.4 XML Gotchas 3.4.1 Embracing Namespaces 3.4.2 Escaping Strings 3.4.3 Whitespace 3.5 Questions and Exercises Chapter 4: Finding Your Way Around with XPath 4.1 XPath Axes 4.2 Node Tests by Kind 4.3 XPath’s Abbreviated Syntax 4.4 XPath Functions 4.5 XPath Tips and Tricks 4.5.1 Wildcards 4.5.2 Value Comparisons 4.5.3 Selecting Multiple Element Names with the Union Operator 4.5.4 Selecting the “Nth” Item or a Range of Items 4.6 Questions and Exercises Chapter 5: XQuery Basics 5.1 The Parts of an XQuery 5.2 Enclosed Expressions and Curly Braces 5.3 FLWOR Expressions 5.3.1 Binding Variables 5.3.2 Iterating over Variables 5.3.3 Filtering Results 5.3.3.1 A Short Note on Comparisons 5.3.4 Ordering Results 5.3.5 Counting Results 5.3.6 Grouping Results 5.4 Conditional Expressions 5.4.1 Effective Boolean Values 5.4.2 The Else Clause Is Required: A Few Tips About Using Conditional Expressions 5.4.3 Chaining Conditional Expressions 5.5 Questions and Exercises Chapter 6: Next Steps with XQuery 6.1 The Built-In Function Library 6.2 Writing Your Own Functions 6.3 Using Library Modules 6.3.1 Importing Library Modules 6.3.2 Creating Your Own Library Modules 6.3.3 Public and Private Functions 6.3.4 Wrapping Up 6.4 Questions and Exercises Chapter 7: Advanced XQuery 7.1 String Constructors 7.2 Maps and Arrays 7.2.1 Revisiting Sequences 7.2.2 Maps 7.2.3 Arrays 7.2.4 Combining Maps and Arrays 7.2.5 Modifying Maps and Arrays 7.3 Windowing 7.3.1 Understanding Tuple Streams 7.3.2 Tumbling Windows 7.3.3 Sliding Windows 7.4 Questions and Exercises Chapter 8: Thinking Functionally 8.1 Immutability 8.2 Maps 8.3 Folds 8.4 Recursion 8.4.1 Transforming Data with Recursive Typeswitch 8.5 Higher-Order Functions 8.6 Questions and Exercises Chapter 9: Modifying Your Data with XQuery Update 9.1 Copying Data 9.2 Transform Expressions 9.2.1 Insert 9.2.2 Delete 9.2.3 Replace 9.2.4 Rename 9.2.5 Transform With 9.3 Updating Expressions 9.3.1 Changing the World 9.3.2 Updating Functions 9.4 Questions and Exercises Chapter 10: Searching with XQuery Full Text 10.1 Finding Patterns with XPath 10.1.1 Searching Substrings 10.1.2 Regular Expressions 10.2 The Full Text Contains Text Operator 10.2.1 Scoring 10.2.2 Any-All Options 10.2.3 Cardinality 10.2.4 Positional Filters 10.2.5 Weighting 10.2.6 Match Options 10.3 Questions and Exercises Chapter 11: Handling Errors Gracefully 11.1 Documenting Your XQuery with XQDoc 11.2 Catching Mistakes Before You Run Anything 11.3 Catching Errors at Runtime 11.4 Unit Testing with XQuery 11.5 Questions and Exercises Chapter 12: Using XQuery with Other Digital Humanities Tools 12.1 XQuery and JSON 12.2 XQuery and CSV 12.3 XQuery and XSLT 12.4 Questions and Exercises Chapter 13: Conclusion 13.1 XQuery Paralipomena 13.1.1 Web Applications 13.1.2 Databases 13.2 The XQuery Community 13.2.1 Books 13.2.2 Digital Forums 13.2.3 Conferences and Training 13.3 Questions and Exercises Acknowledgments Notes About the Authors Index
Similar books
MySQL® Notes for Professionals book
2018 · PDF
MrExcel 2022: Boosting Excel
2022 · PDF
MrExcel 2022: Boosting Excel
2022 · PDF
Session C11: Ancient Cultural Landscapes in South Europe – their Ecological Setting and Evolution, Session C22: Gardeners from South America, Session S04: Agro-Pastoralism and Early Metallurgy Sessions, Session WS29: The Idea of Enclosure in Recent Iberian Prehistory, Session C88: Rhytmes et causalites des dynamiques de l'anthropisation en Europe entre 6500 ET 500 BC: Hypotheses socio-culturelles et/ou climatiques: Proceedings of the XV UISPP World Congress (Lisbon 4-9 September 2006) / Actes du XV Congrès Mondial (Lisbonne 4-9 Septembre 2006) Vol.36
2010 · PDF
THE BRITISH ARMY IN INDIA: ITS PRESERVATION BY AN APPROPRIATE CLOTHING, HOUSING, LOCATING, RECREATIVE EMPLOYMENT, AND HOPEFUL ENCOURAGEMENT OF THE TROOPS. with AN APPENDIX ON INDIA : THE CLIMATE OP ITS HILLS ; THE DEVELOPMENT OF ITS RESODRCBS, INDUSTRY, AND ARTS ; THE ADMINISTRATION OF JUSTICE ; THE BLACK ACT ; THE PROGRESS OF CHRISTIANITY ; THE TRAFFIC IN OPIUM ; THE VALUE OF INDIA ; PERMANENT CAUSES OF DISAFFECTION, AND OF THE RECENT REBELLION ; THE TRADITIONARY POLICY; MISGOVERNMENT BY NATIVE RULERS ; ANNEXATIONS OF THEIR TERRITORY, ETC.
1858 · PDF
Idries Shah 27 Books Collection : A Perfumed Scorpion, A Veiled Gazelle, Caravan of Dreams, Darkest England, Destination Mecca, Evenings with Idries Shah, Knowing How to Know, Learning How to Learn, Letters and Lectures of Idries Shah, Neglected aspects of Sufi study, Observations, Oriental Magic, Reflections, Seeker after Truth, Special Illumination, Special Problems in the study of Sufi ideas, Sufi thought and action, Tales of the Dervishes, The Dermis Probe, The Elephant in the Dark, The Englishman Handbook, Idries Shah Antology, The Magic Monastery, The natives are restless, wisdom of the Idiots PDF.
2022 · PDF
The travels of Capts. Lewis and Clarke from St. Louis, by way of the Missouri and Columbia rivers, to the Pacific ocean; performed in the years 1804, 1805 & 1806, by order of the government of the United States. Containing delineations of the manners, customs, religion, &c. of the Indians, comp. from various authentic sources, and original documents, and a summary of the Statistical view of the Indian nations, from the official communication of Meriwether Lewis. Illustrated with a map of the country, inhabited by the western tribes of Indians
1809 · PDF
Professional Linux kernel architecture ''Wrox programmer to programmer''--Cover. - ''What you are reading right now is the result of an evolution over more than seven years: After two years of writing, the first edition was published in German by Carl Hanser Verlag in 2003. It then described kernel 2.6.0. The test was used as a basis for the low-level design documentation for the EAL4+ security evaluation of Red Hat Enterprise Linux 5, requiring to update it to kernel 2.6.18 (if the EAL acronym does not mean anything to you, then Wikipedia is once more your friend). Hewlett-Packard sponsored the translation into English and has, thankfully, granted the rights to publish the result. Updates to kernel 2.6.24 were then performed specifically for this book''--P. ix
2008 · PDF