Skip to content

CLI

Command-line interface documentation for Lacuna.

Overview

Lacuna provides a subcommand-based CLI for running lesion network mapping analyses, managing connectomes, and organizing data using BIDS-style naming conventions.

lacuna <command> [options]

Commands

  • Check


    Validate input masks and check output completeness.

  • Bidsify


    Convert a directory of NIfTI mask files to BIDS format.

  • Collect


    Aggregate subject-level parcelstats into group-level tables.

  • Fetch


    Download normative connectomes and other assets to the local cache.

  • Info


    Display available resources (atlases, connectomes).

  • Run


    Run lesion analyses (regional damage, functional and structural network mapping).

  • Tutorial


    Setup tutorial data for learning Lacuna.

Quick Usage

# Setup tutorial data
lacuna tutorial ./my_tutorial

# Fetch a connectome
lacuna fetch gsp1000 --api-key $DATAVERSE_API_KEY

# Run regional damage analysis
lacuna run rd /bids /output --parcel-atlases schaefer2018parcels100networks7

# Run functional network mapping
lacuna run fnm /bids /output --connectome-path /path/to/gsp1000_batches

# Aggregate results across subjects
lacuna collect /bids /output

# Check for missing outputs after a batch run
lacuna check rd /bids /output

# List available atlases
lacuna info atlases

Getting Help

# General help
lacuna --help

# Command-specific help
lacuna run --help
lacuna run fnm --help
lacuna fetch --help