Skip to content

Create a basic tutorial for DimensionalData - basic_tutorial.md#1198

Open
willbodeau wants to merge 28 commits into
rafaqz:mainfrom
willbodeau:tutorial_basic
Open

Create a basic tutorial for DimensionalData - basic_tutorial.md#1198
willbodeau wants to merge 28 commits into
rafaqz:mainfrom
willbodeau:tutorial_basic

Conversation

@willbodeau

Copy link
Copy Markdown

Introduces DimensionalData using toy satellite data, explaining the basics of the package: constructing DimArray and DimStack, lookups, selectors, groupby, constructing new stacks using set, dimension-aware broadcasting. Concepts are motivated by some simplified real world questions.

@alex-s-gardner

Adds a tutorial that introduces DimensionalData to users new to the package, using toy satellite data.

Explains DimensionalData features in a real-world narrative, implementing features to address simplified, realistic questions.

docs/src/dimensionaldata_tutorial.md: executable @example chunks and figures.

docs/src/.vitepress/config.mts: add tutorial to navbar.
Increased the heatwave in toy data generation so it is clearly visible.
Trim temperature output to just a preview
Add `nothing` to toy data generation chunk
Shorten them for simplicity, move on to tutorial content
Suppressed PRNG output, fixed phrasing describing dimension names for clarity
Suppress output. using semicolons instead of `nothing`, change title
dimensionaldata -> basic
@rafaqz

rafaqz commented Jun 1, 2026

Copy link
Copy Markdown
Owner

Thanks! I will try to look through it later in the week

@codecov

codecov Bot commented Jun 1, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.15%. Comparing base (4b5b8b0) to head (ab7d27b).
⚠️ Report is 1 commits behind head on main.

❗ There is a different number of reports uploaded between BASE (4b5b8b0) and HEAD (ab7d27b). Click for more details.

HEAD has 6 uploads less than BASE
Flag BASE (4b5b8b0) HEAD (ab7d27b)
7 1
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1198      +/-   ##
==========================================
- Coverage   86.99%   80.15%   -6.84%     
==========================================
  Files          61       61              
  Lines        5850     5851       +1     
==========================================
- Hits         5089     4690     -399     
- Misses        761     1161     +400     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Comment thread docs/src/basic_tutorial.md Outdated
Update docs/src/basic_tutorial.md

Co-authored-by: Felix Cremer <fcremer@bgc-jena.mpg.de>

@alex-s-gardner alex-s-gardner left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great start! Work through this review then we can discuss further.

Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md
Comment thread docs/src/basic_tutorial.md Outdated
Implemented wording suggestions to the TOC and throughout the tutorial.

Added packages at beginning of tutorial
Replace satellite_data with climate as the variable name

Refactor code for simplicity
Updated heatmaps of temperature to be more useful, concise.

Fixed wording of things for accuracy
Refactor code for clarity:

la/lo->lat/lo, lat/lon -> lats/lons throughout

Expand one-liners into their individual components

Update heatmaps for simplicity
Introduce `@dim` macro and explanation
Comment thread docs/src/basic_tutorial.md Outdated
Update headers, table of contents, anchor links
Add more motivation and explanation to the selector functions with basic examples.
Update data generation comments after changing from Kelvin to Celsius

Suppress output using `nothing #hide`
Update TOC and headers, nest the `Question 1` headers so they dont appear in the sidebar.
Revise all parts of question 2 to use a more simple example to introduce dimension-aware broadcasting and stacks with non-matching layers.
Reword parts of question 2 for clarity
Correct grammar, punctuation, and sentence clarity.

Change the code chunk that produces the intentional error so it doesn't execute

Remove headers on the Questions 1 and 2 lines.

@asinghvi17 asinghvi17 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks generally good, just some small suggestions

Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
willbodeau and others added 2 commits June 30, 2026 14:43
Co-authored-by: Anshul Singhvi <anshulsinghvi@gmail.com>
Co-authored-by: Anshul Singhvi <anshulsinghvi@gmail.com>
willbodeau and others added 3 commits June 30, 2026 14:43
Co-authored-by: Anshul Singhvi <anshulsinghvi@gmail.com>
Co-authored-by: Anshul Singhvi <anshulsinghvi@gmail.com>
Co-authored-by: Anshul Singhvi <anshulsinghvi@gmail.com>

@asinghvi17 asinghvi17 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

my bad

Comment thread docs/src/basic_tutorial.md Outdated
Comment thread docs/src/basic_tutorial.md Outdated
Co-authored-by: Anshul Singhvi <anshulsinghvi@gmail.com>

@alex-s-gardner alex-s-gardner left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this is almost ready to merge

Comment thread docs/src/basic_tutorial.md Outdated

To answer our second question, we will be working with arrays of two different shapes: the full temperature field (latitude, longitude, and time) and the global daily mean (time only). The motivation behind this is to demonstrate working with a DimStack whose layers don't completely match.

## Build a DimStack of DimArrays with differing shared dimensions

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great example!

Changed sentence describing Bins as a function to describing it as a Type.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants