barplot-long-labels

Create publication-quality horizontal barplots with long y-axis labels using ggplot2.

Updated Jun 13, 2025
One-click install
npx skills add https://github.com/sahuno/llm_configs --skill barplot-long-labels
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: barplot-long-labels
Source: https://github.com/sahuno/llm_configs/tree/main/claude/skills/barplot-long-labels
Command: npx skills add https://github.com/sahuno/llm_configs --skill barplot-long-labels

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This skill automates the creation of horizontal barplots when y-axis labels are long, calculating optimal width and height so labels always fit and plots remain publication-ready.

Core Features & Use Cases

  • Automatically computes dimensions based on label length and item count to ensure legibility.
  • Supports GO, KEGG, and Reactome pathway visuals and other long-label datasets.
  • Provides a ready-to-use workflow for producing high-quality figures for manuscripts and reports.

Quick Start

Provide a dataset with a Description column and a value column, then request a horizontal barplot that auto-sizes to accommodate long labels.

Frequently Asked Questions about barplot-long-labels

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a horizontal barplot in R when y-axis labels are too long?

To create a horizontal barplot with long labels, you can use a skill that automatically computes width and height from label length and item count, rendering the figure with ggplot2 so lengthy category names always fit.

How do I visualize GO, KEGG, or Reactome enrichment results with lengthy descriptions?

You can visualize enrichment results by providing a dataset with Description and value columns, then generating an auto-sized horizontal barplot that accommodates long pathway names for publication-ready reports.

Does ggplot2 automatically adjust plot dimensions for long text labels?

Standard ggplot2 does not auto-adjust overall plot dimensions for text length, but specialized skills can calculate optimal width and height from your label strings to ensure legibility without manual resizing.

What is the best way to format enrichment barplots for manuscripts without cutting off text?

The best way to format manuscript-ready enrichment barplots is to dynamically compute image dimensions based on the maximum label length and item count, ensuring all text fits within the final exported figure.

Can I use this horizontal barplot approach for datasets other than pathway analysis?

Yes, this approach works for any dataset featuring lengthy category names, as it dynamically sizes the figure based on generic label lengths and item counts rather than requiring pathway-specific data structures.