rf-model-importance-analysis

rf-model-importance-analysis is a skill for Claude Code, Codex from aipoch/medical-research-skills. It costs 64 tokens per session (2,828 once invoked), scanned A, original, MIT.

A reproducible R workflow that trains a two-group random-forest model from an expression-like feature table and ranks which inputs matter most. A random forest is a model made from many decision trees used together for classification.

In plain words
What is it for?
It helps compare a case group with a control group, rank important features, create error and importance plots, tune forest settings, and rerender plots from an RDS result file. It is not intended for regression, multi-class classification, or missing-data filling.
Why use it?
It standardises the analysis settings, importance ranking, error checks, and plots so the same inputs and seed can reproduce the results. It also supports rerendering plots from an existing saved result.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It helps compare a case group with a control group, rank important features, create error and importance plots, tune forest settings, and rerender plots from an RDS result file. It is not intended for regression, multi-class classification, or missing-data filling.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/aipoch/medical-research-skills/rf-model-importance-analysis
About the project

Medical Research Agent Skills is a library of agent instructions for medical and biomedical research, covering evidence analysis, study protocol design, data analysis, and academic writing. Researchers use it to guide compatible coding agents through common scientific workflows. The catalogue contains many of the library's skills and commands.

aipoch/medical-research-skills · 1,860 stars · on GitHub · aipoch.com

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add aipoch/medical-research-skills --skill rf-model-importance-analysis
Clone the repo
git clone --depth 1 https://github.com/aipoch/medical-research-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for rf-model-importance-analysis

README.md
[![agentmods](https://agentmods.dev/badge/skills/aipoch/medical-research-skills/rf-model-importance-analysis/github.svg)](https://agentmods.dev/skills/aipoch/medical-research-skills/rf-model-importance-analysis)
Your own site
<a href="https://agentmods.dev/skills/aipoch/medical-research-skills/rf-model-importance-analysis"><img src="https://agentmods.dev/badge/skills/aipoch/medical-research-skills/rf-model-importance-analysis/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for rf-model-importance-analysis

Your own site · 80×15
<a href="https://agentmods.dev/skills/aipoch/medical-research-skills/rf-model-importance-analysis"><img src="https://agentmods.dev/badge/skills/aipoch/medical-research-skills/rf-model-importance-analysis.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 64 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,828 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00064 $0.02828
Opus 5 $0.00032 $0.01414
Sonnet 5 $0.00013 $0.00566
Haiku 4.5 $0.00006 $0.00283

Measured 12d ago against content hash 37c7e58fa30c, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

rf-model-importance-analysis scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 12d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

awesome-med-research-skills/Data Analysis/rf-model-importance-analysis/SKILL.md · 238 lines

How it starts

The opening of the file, as written. The whole thing — 238 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Source: https://github.com/aipoch/medical-research-skills

RF Model Importance Analysis

Quick Start

Use one of these three commands first, then consult the full argument table only if you need extra tuning.

1. Standard Run

Rscript scripts/main.R \
  --input_file tests/data/expression_matrix.csv \
  --group_file tests/data/group_info.csv \
  --case_group AR \
  --control_group Control \
  --output_dir tests/output/manual-test \
  --seed 42 \
  --timeout_seconds 300

2. Tuned Importance Run

Rscript scripts/main.R \
  --input_file tests/data/expression_matrix.csv \
  --group_file tests/data/group_info.csv \
  --case_group AR \
  --control_group Control \
  --output_dir tests/output/custom-importance \
  --seed 42 \
  --rf_ntree 800 \
  --rf_mtry 4 \
  --rf_imp_type 2 \
  --rf_imp_threshold 1 \
  --rf_top_n 8 \
  --rf_importance_top_n 8 \
  --timeout_seconds 300

3. Plot-Only Rerender

Run this only after a full analysis has already created output_dir/data/rf_result.rds.

Rscript scripts/main.R \
  --plot_only TRUE \
  --output_dir tests/output/manual-test \
  --seed 42 \
  --timeout_seconds 300

When to Read External Files

Situation File to Read Purpose
Need algorithm details references/algorithm.md Explain random forest modeling, importance metrics, assumptions, and result interpretation
Need to execute the analysis scripts/main.R Run the CLI entry point with a complete Rscript command
Encounter an error references/troubleshooting.md Map error codes to causes and fixes
Need CLI examples references/cli-guide.md See installation steps and runnable command examples
Need a runnable smoke test tests/data/ Use the bundled small dataset for verification

Stop Conditions

Do not use this skill when any of the following is true:

  • The task is regression, multiclass classification, time-series modeling, or remote data fetching.
  • The input still requires imputation, normalization, batch correction, or other preprocessing.
  • The feature matrix contains missing values, non-numeric feature columns, or mismatched sample IDs.

Read the full file on GitHub · 238 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 12d ago First seen · 238 lines · 64 tokens per session scan A 37c7e58fa30c

Subscribe to this mod's changes

rf-model-importance-analysis is a skill published in the GitHub repository aipoch/medical-research-skills (1,860 stars, last pushed 1mo ago), licensed MIT. It adds 64 tokens to every session and 2,828 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other skills, from other repositories