Skip to article frontmatterSkip to article content

πŸ“š How to Edit Documentation

Simple guide for lab members to update docs.cnclab.io

πŸš€ Adding Research Notebooks (Most Common)ΒΆ

  1. Create or open your notebook in Google Colab

  2. Name your file using our convention:

    Category-##-Title.ipynb
    
    Examples:
    Analysis-01-Reproducible_fMRI.ipynb
    Methods-01-Data_Quality_Checks.ipynb
    Tutorials-01-Python_Setup.ipynb
    Resources-01-Lab_Onboarding.ipynb
  3. Save to GitHub:

    • File β†’ Save a copy in GitHub

    • Repository: CNClaboratory/cnclab_website

    • File path: docs-book/notebooks/Category-##-Title.ipynb

  4. Auto-deploy: Your notebook appears on docs.cnclab.io in 2-3 minutes

CategoriesΒΆ

✏️ Editing Text Content¢

Quick Edits (GitHub Web Editor)ΒΆ

  1. Navigate to any page on docs.cnclab.io

  2. Click β€œEdit this page” (GitHub icon) at the top

  3. Make changes in GitHub’s web editor

  4. Commit with a clear message: feat: Update [page name] - [what changed]

  5. Changes go live in 2-3 minutes

Directory-based Organization (No manual TOC edits)ΒΆ

You can now organize pages using folders and numeric prefixes. The site auto-generates the table of contents from the directory tree.

RulesΒΆ

ExamplesΒΆ

docs-book/
β”œβ”€β”€ index.md                  # Always pinned first
β”œβ”€β”€ editing-guide.md          # Pinned
β”œβ”€β”€ ACCESS_CONTROL.md         # Pinned
β”œβ”€β”€ Tutorials/
β”‚   β”œβ”€β”€ 01-Getting-Started.md
β”‚   β”œβ”€β”€ 02-Python-Setup.ipynb
β”‚   └── Advanced/
β”‚       β”œβ”€β”€ 01-Vectorization.md
β”‚       └── 02-Numba.md
└── Methods/
    β”œβ”€β”€ 01-Data-Quality.md
    └── 02-Preprocessing.md

No need to edit myst.yml for ordering or nestingβ€”it’s generated at build time.

Files You Can EditΒΆ

docs-book/
β”œβ”€β”€ index.md              # Homepage
β”œβ”€β”€ editing-guide.md      # This guide
β”œβ”€β”€ notebooks/            # Research notebooks
β”‚   β”œβ”€β”€ Analysis-XX-*.ipynb
β”‚   β”œβ”€β”€ Methods-XX-*.ipynb
β”‚   β”œβ”€β”€ Tutorials-XX-*.ipynb
β”‚   └── Resources-XX-*.ipynb
└── myst.yml             # Auto-updated TOC (advanced; no edits needed)

πŸ”§ Advanced: Table of ContentsΒΆ

To add new sections or reorder content, edit docs-book/myst.yml:

toc:
  - title: Home
    file: index.md
  - title: 🧠 Research Analysis
    children:
      - title: Your New Analysis
        file: notebooks/Analysis-02-YourStudy.ipynb

πŸ“ Writing in MyST MarkdownΒΆ

Basic SyntaxΒΆ

# Main Heading
## Subheading

**Bold text** and *italic text*

- Bulleted lists
1. Numbered lists

[Links](https://example.com)

Advanced FeaturesΒΆ

# Cross-references
{doc}`other-page` or {doc}`notebooks/Analysis-01-Reproducible_fMRI`

# Admonitions  
:::{note}
Important information here
:::

:::{warning}
Be careful with this!
:::

# Code blocks
```python
import pandas as pd
# Your code here

## πŸ†˜ Getting Help

- **Quick questions**: Edit this page to add common issues
- **Technical problems**: [Open a GitHub issue](https://github.com/CNClaboratory/cnclab_website/issues)
- **Major changes**: Contact lab administrators

## βœ… Quality Guidelines

Before publishing content:

- [ ] **Test notebooks** - "Restart and run all" works completely
- [ ] **Clear documentation** - Every step explained
- [ ] **Proper naming** - Follows Category-##-Title convention
- [ ] **Complete outputs** - All results and figures preserved
- [ ] **Bibliography** - Citations for methods and datasets used

---

**Remember**: This documentation follows [open science principles](https://www.poldracklab.org/) - be transparent, reproducible, and helpful to others!