Evo protein expression analysis

From OpenLAIR/OpenSkill · View interactive version

Evo protein expression analysis is an AI agent skill from the GitHub repository OpenLAIR/OpenSkill. Use when populating Excel workbooks for quantitative proteomics tasks - computing expression lookups, group statistics, and log2 fold-change values using Python and writing numeric results via openpyxl while preserving cell formatting. Handles two-sheet workbooks (Task + Data) with 2D protein×sample

How to use this skill

Skill file

evo-protein-expression-analysis

Utilities for populating Excel workbooks with proteomics expression values,

group statistics, and fold-change calculations while preserving all cell formatting.

CRITICAL: Write computed numeric values, NOT formulas

openpyxl does NOT have a calculation engine. If you write Excel formulas (strings

starting with =), they will only be evaluated when the file is opened in Excel.

Tools that read the file with data_only=True will see None for all formula cells.

You MUST compute values in Python and write float/int results directly.

Key facts about the protein_expression.xlsx task

Critical rules

  1. Write computed numeric values, not formulas — openpyxl doesn't evaluate formulas.
  2. Load with data_only=False to preserve existing formatting; only set .value on target cells.
  3. Data is already log2-transformed: use regular mean/stdev; Log2FC = Treated_Mean − Control_Mean; Fold Change = 2^Log2FC.
  4. Use Python's statistics.mean() and statistics.stdev() (sample stdev) for calculations.
  5. Group classification comes from text values in row 9 ("Control" / "Treated").
  6. Sample names in the Data sheet may have prefixes like "MDAMB468_BREAST_TenPx01" — match exactly against Task row 10.
  7. Do not alter file format, colors, fonts, or add macros/VBA.
  8. Setting cell.value preserves existing cell formatting (fill, font, border).

Usage

import sys
sys.path.insert(0, '/root/.claude/skills/evo-protein-expression-analysis/scripts')
from utils import populate_protein_expression_task

# One-shot populate the standard task:
populate_protein_expression_task('/root/protein_expression.xlsx')

Alternate usage (step-by-step)

import sys
sys.path.insert(0, '/root/.claude/skills/evo-protein-expression-analysis/scripts')
from utils import (
    load_workbook_preserving,
    save_workbook_safely,
    build_data_index,
    classify_group_columns,
    fill_expression_values,
    compute_group_stats,
    compute_fold_changes,
)

wb = load_workbook_preserving('/root/protein_expression.xlsx')
ws_task = wb['Task']
ws_data = wb['Data']

# Build lookup index from Data sheet
data_index = build_data_index(ws_data)

# Detect Control/Treated grouping from row 9
groups = classify_group_columns(ws_task, group_row=9, start_col=3, end_col=12)

# Step 1: Fill expression values (numeric)
fill_expression_values(ws_task, data_index)

# Step 2: Compute and write statistics (numeric)
compute_group_stats(ws_task, groups=groups)

# Step 3: Compute and write fold changes (numeric)
compute_fold_changes(ws_task)

save_workbook_safely(wb, '/root/protein_expression.xlsx')

Output validation

After running, the following cells must contain numeric values (int or float):

No cell formatting (fills, fonts) should change.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.