Claude-skill-registry hic-normalization
Automatically detect and normalize Hi-C data. Only .cool or .mcool file is supported. All .mcool files are then checked for existing normalization (supports bins/weight only) and balanced if none of the normalizations exist.
install
source · Clone the upstream repo
git clone https://github.com/majiayu000/claude-skill-registry
Claude Code · Install into ~/.claude/skills/
T=$(mktemp -d) && git clone --depth=1 https://github.com/majiayu000/claude-skill-registry "$T" && mkdir -p ~/.claude/skills && cp -r "$T/skills/data/16-toolbased-hic-normalization" ~/.claude/skills/majiayu000-claude-skill-registry-hic-normalization && rm -rf "$T"
manifest:
skills/data/16-toolbased-hic-normalization/SKILL.mdsource content
Overview
This skill performs Hi-C data normalization on .mcool files.
Main steps include:
- Refer to the Inputs & Outputs section to verify required files and output structure.
- Check normalization status per resolution (supports bins/weight columns only).
- If a resolution is not normalized, perform normalization with cooler balance (ICE) to create bins/weight.
- Verify normalization and emit a concise report on the file, resolution, and normalization status.
When to use this skill
Use the hic-normalization pipeline when:
- You need to ensure that Hi-C data is normalized for downstream analysis.
- Your data comes in .cool or .mcool formats, and you want to check or refresh normalization status (ICE normalization).
This tool assumes the file already has correct genome assembly and chromosome names.
Inputs & Outputs
Inputs
- Accepted file format: .mcool
Outputs
${sample}_hic_norm/ ${sample}_norm.mcool normalization_report.txt # A brief log/report indicating which resolutions were detected, normalized, or skipped.
Decision Tree
Step 0 — Gather Required Information from the User
Before calling any tool, ask the user:
- Sample name (
): used as prefix and for the output directorysample
.${sample}_hic_norm - Genome assembly (
): e.g.genome
,hg38
,mm10
.danRer11- Never guess or auto-detect.
- Hi-C matrix path (
): e.g.mcool_path
file path or.mcool
file path..hic
(.mcool file without resolution specified)path/to/sample.mcool- or
file path.hic
Step 1: Initialize Project
- Make director for this project:
Call:
mcp__project-init-tools__project_init
with:
: the user-provided sample namesample
: hic_normtask
The tool will:
- Create
directory.${sample}_hic_norm - Get the full path of the
directory, which will be used as${sample}_hic_norm
.${proj_dir}
- If the user provides a
file, convert it to.hic
file first using.mcool
tool:mcp__HiCExplorer-tools__hic_to_mcool
Call:
mcp__HiCExplorer-tools__hic_to_mcool
with:
: the user-provided path (e.g.input_hic
)input.hic
: the user-provided sample namesample
: directory to save the view file. In this skill, it is the full path of theproj_dir
directory returned by${sample}_hic_norm
.mcp__project-init-tools__project_init
: the user-provided resolutions (e.g.resolutions
)[50000]
The tool will:
- Convert the
file to.hic
file..mcool - Return the path of the
file..mcool
If the conversion is successful, update
${mcool_uri} to the path of the .mcool file. The ${mcool_path} should be updated to the path of the .mcool file without resolution specified.
- Inspect the
file to list available resolutions and confirm the analysis resolution with the user..mcool
Call:
mcp__cooler-tools__list_mcool_resolutions
with:
: the user-provided path (e.g.mcool_path
) or the path of theinput.mcool
file returned by.mcoolmcp__HiCExplorer-tools__hic_to_mcool
The tool will:
- List all resolutions in the .mcool file.
- Return the resolutions as a list.
Step 2: Check Normalization Status (per resolution) on .mcool and normlize if missing
Call:
mcp__cooler-tools__check_and_balance_mcool
with:
: the user-provided sample namesample
: the full path to the project directoryproj_dir
: the path to the .mcool file (e.g. input.mcool) without resolution specified.mcool_path
: if true, runbalance_missing
on resolutions missing /bins/weightcooler.balance_cooler
: the name of the weight column to write into bins (default: 'weight')store_name
: the number of diagonals to ignore (ignore_diags
in cooler.balance_cooler)ignore_diags
: themad_max
parameter for cooler.balance_cooler (default: cooler's own)mad_max
: the convergence tolerance, maps toconverge
in cooler.balance_coolertol
: themax_iters
parameter for cooler.balance_coolermax_iters
: if true, balance cis contacts only (cis_only
)cis_only=True
The tool will:
- Check the normalization status (per resolution) on the .mcool file.
- If the normalization is missing, balance the .mcool file.
- Return the path of the balanced .mcool file under
directory.${proj_dir}/
Notes & Troubleshooting
- Normalization fails to converge: Increase iterations or adjust the convergence criteria (--max-iters, --converge)