> ## Documentation Index
> Fetch the complete documentation index at: https://docs.atomscale.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# SIMS

> Depth profiling of elemental composition from secondary ion mass spectrometry

SIMS (Secondary Ion Mass Spectrometry) analysis parses depth profile data from Excel files, extracting concentration-vs-depth curves for each detected ionic species. The pipeline automatically identifies depth and species columns, detects measurement units from column headers, and produces aligned depth profile arrays.

## Overview

The SIMS pipeline processes data in three stages:

1. **Sheet detection**: locates the correct worksheet in the uploaded Excel file by looking for a "Processed data" sheet or falling back to the first sheet with numeric data
2. **Column identification**: pattern-based matching separates the depth column from species concentration columns, and detects units from the column headers
3. **Data extraction**: produces aligned depth and concentration arrays for each species, with metadata recording the species detected and units used

### Key Metrics

| Metric        | What It Tells You                                                                                            |
| ------------- | ------------------------------------------------------------------------------------------------------------ |
| Depth         | Sputter depth or time into the sample. Reported in nm, um, or seconds depending on the measurement.          |
| Concentration | Elemental abundance at each depth point. Units depend on the instrument output: at/cm³, at%, or wt%.         |
| Species       | The ionic species detected in the measurement. Each species produces a separate depth-concentration profile. |

<Tabs>
  <Tab title="Guide">
    ### Adding Data

    Upload Excel files (.xls or .xlsx) containing depth profile data through the data page. Processing starts automatically once the upload completes.

    The pipeline expects a worksheet with a depth column and one or more numeric columns for species concentrations. Column headers should include unit information (e.g., "Depth (nm)", "Si (at/cm³)") for automatic unit detection.

    ### Viewing Results

    Once processing completes, the workspace displays depth profiles with concentration plotted against depth. Each detected species appears as a separate series on the chart, allowing you to compare elemental distributions across the sample cross-section.

    <Tip>
      If the automatic unit detection picks the wrong units, you can override depth and concentration units by specifying them in the pipeline inputs before re-running analysis.
    </Tip>
  </Tab>

  <Tab title="Technical Details">
    ### Analysis Pipeline

    The SIMS pipeline processes each uploaded Excel file through three stages.

    #### Stage 1: Sheet Detection

    The parser locates the correct worksheet in the uploaded file, looking for a processed data sheet or falling back to the first sheet with numeric data.

    #### Stage 2: Column Identification

    Columns are automatically classified as depth or species concentration based on header text. Units (nm, um, s for depth; at/cm³, at%, wt% for concentration) are detected from column headers. Both depth and concentration units can be overridden via pipeline inputs if automatic detection is incorrect.

    #### Stage 3: Data Extraction

    The pipeline cleans the data and produces aligned depth and concentration arrays for each species.
  </Tab>
</Tabs>
