SEARCH Advanced Search Topic All Topics Algebra Applied Mathematics Calculus and Analysis Chemistry Computer Science Courseware Differential Equations Discrete Mathematics Earth Sciences Economics and Finance Engineering Geometry Graphics Life Sciences Modeling and Simulation Number Theory Physics Probability and Statistics Programming Recreational Social Sciences Tutorial and Reference Language All Languages English Bulgarian Catalan Chinese Dutch Finnish French German Greek Hungarian Italian Japanese Korean Lithuanian Norwegian Polish Portuguese Russian Spanish Swedish
 BROWSE TOPICS Algebra» Applied Mathematics» Calculus and Analysis» Chemistry» Computer Science» Courseware» Differential Equations» Discrete Mathematics» Earth Sciences» Economics and Finance» Engineering» Geometry» Graphics» Life Sciences» Modeling and Simulation» Number Theory» Physics» Probability and Statistics» Programming» Recreational» Social Sciences» Tutorial and Reference»
Query: Getting Information from Data with the Wolfram Language
by Seth J. Chandler
• Publisher: Wolfram Media
• Year: 2023
• ISBN: 9781579550851 (Paperback)
• 368 pp
Description

Mathematica and the Wolfram Language provide an integrated environment for sophisticated programming, making them the ideal tools for calculus, data visualization, machine learning, and more. But how about using Wolfram as the linchpin for organizing data? In this book, Professor Seth J. Chandler, an award-winning, 30-year user of the Wolfram Language, guides intermediate users from simple cases to data in the wild and shows how each can be fed into the full range of Wolfram Language functionality. It's both a conceptual and practical approach filled with annotated examples.

Want to know more about associations or the organization and presentation of datasets? This book shows how it's done. Want to organize or reduce data in the Wolfram Language similarly to the way one might use SQL, pandas in Python, or dplyr in R's tidyverse? This book shows how to simplify data processing and go beyond what is possible with other tools using the Query function. It also explores how to import information from the places real-world data is most likely to be found: CSV, Excel, or JSON files.

Use Query both as a tutorial and as a reference. Read it cover-to-cover doing the exercises or dip in to look up specific data-wrangling tasks. Augmenting the underlying power of the Wolfram Language with the techniques taught in this book puts you at the forefront of innovative data analysis.

Contents
Introduction
Purpose · Audience · How to Read This Book · Chapter Roadmap · Version · Front End · Repositories · Conventions · Exercises · Technical Notes · A Little about Me

Data Structures and Functions
The Mathematica Expression · The Part Function · The Function · The List · Levels · Position: Part and Level · Functional Programming Constructs · Common Operations on Lists · A Sample Problem Using "Old-School" Wolfram Language Methods · Conclusion

Association
A Home-Brewed Indexed Data Structure · The Association · Using Part with Association · Functions on Associations · Associations inside Other Expressions · Position on Association · KeyTake and KeyDrop · Lookup · Building Associations · Functional Programming Constructs Used on Associations · Apply and Transpose · KeyMap · KeyValueMap · The KeyReplace Resource Function · Select · GatherBy · GroupBy · Associations as Functions · Putting It Together: More Complex Operations Using Operators and Composition

Query
Query Structure · Order of Operations in Query · Four Complications · Solve Sample Problems with Query · How to Do Nothing: All or Identity · Queries with Deeply Nested Datasets · Functions That Create Queries · Debugging Queries That Go Wrong

The Dataset
Introduction · Inside the Datasets · Dataset Presentation

Basic Recipes
Introduction · Get the Dimensions of a Dataset · Rename All of the Columns · Rename Just Some of the Columns · Sort Rows and Columns · Sort Groupings · Sample the Rows · Replace Some Key-Value Pairs in an Association: The Association Override Feature · Keep and Drop Rows or Columns · Join Columns Based on Precomputed Data · Join a Column to a Dataset Based on Values in the Existing Columns · Change the Value of an Existing Column: Row-Wise · Add Row Headers (Indexing) · Delete Row Headers · Turn Row Headers into Columns · Give a Column Orientation to a Dataset · Give a Row Orientation to a Dataset · Transpose Datasets and the Double Transpose Trick · Defer Operation of a Descending Operator