← 返回
数据分析 中文

Debugging R Environment And Dependencies

Diagnose and fix R environment issues, including package installation failures, dependency conflicts, system library problems, renv errors, and Bioconductor...
诊断并修复 R 环境问题,包括包安装失败、依赖冲突、系统库问题、renv 错误以及 Bioconductor 相关问题。
jackkuo666
数据分析 clawhub v0.1.0 1 版本 99883.6 Key: 无需
★ 0
Stars
📥 858
下载
💾 13
安装
1
版本
#latest

概述

Debugging R Environment and Dependencies

This skill focuses on resolving problems related to R environments rather than analysis logic. It helps restore a working setup so that R scripts and projects can run successfully.

Use this skill when the user encounters:

  • Package installation failures
  • Version conflicts between packages
  • renv or packrat environment issues
  • Bioconductor version mismatches
  • System dependency errors (e.g., missing compilers or libraries)
  • R failing to start or load packages

What This Skill Does

When activated, this skill will:

  1. Diagnose the environment
    • Check R version
    • Check installed packages and versions
    • Inspect renv.lock or project library
    • Identify Bioconductor version compatibility
  1. Resolve package installation issues
    • Suggest correct CRAN/Bioconductor repositories
    • Install missing system dependencies (e.g., libxml2, curl, openssl)
    • Handle compilation failures on Linux/macOS/Windows
  1. Fix dependency conflicts
    • Align package versions
    • Reinstall broken packages
    • Clean corrupted package libraries
  1. Repair project environments
    • Restore with renv::restore()
    • Rebuild renv.lock
    • Reinitialize project library if needed
  1. Bioconductor troubleshooting
    • Match Bioconductor version to R version
    • Use BiocManager::install() correctly
    • Resolve common bioinformatics package errors
  1. System-level troubleshooting
    • Install missing compilers (e.g., gcc, gfortran)
    • Install development libraries required for R packages
    • Fix PATH or permission issues

Example User Requests That Should Trigger This Skill

  • "I can't install tidyverse"
  • "This package fails with a compilation error"
  • "renv restore is broken"
  • "Bioconductor says my version is incompatible"
  • "library() fails even though the package is installed"
  • "R says shared object cannot be loaded"

Example Workflow

User: I get an error when installing sf.

Skill actions:

  • Detect missing system libraries (GEOS, GDAL, PROJ)
  • Provide OS-specific install commands
  • Retry R package installation
  • Confirm successful library loading

Common Problem Categories

CategoryExamples
-------------------
Missing system libsxml2, curl, openssl, sf, rJava
Compiler issuesgfortran missing, Xcode tools missing
Version mismatchold R vs new package
Bioconductor mismatchwrong Bioc version for R
renv problemscorrupted cache, lockfile mismatch
Permission issuescannot write to library path

Notes

  • Do not modify analysis code unless necessary
  • Prefer fixing the environment over rewriting scripts
  • Always aim to make the project reproducible
  • Recommend renv for future environment stability

版本历史

共 1 个版本

  • v0.1.0 当前
    2026-03-29 17:35 安全 安全

安全检测

腾讯云安全 (Keen)

安全,无风险
查看报告

腾讯云安全 (Sanbu)

安全,无风险
查看报告

🔗 相关推荐

developer-tools

Sci Hub Search

jackkuo666
通过Sci-Hub搜索和下载学术论文的AI工具
★ 3 📥 1,271
data-analysis

Excel / XLSX

ivangdavila
创建、检查和编辑 Microsoft Excel 工作簿及 XLSX 文件,支持可靠的公式、日期、类型、格式、重算及模板保留功能。
★ 368 📥 140,767
data-analysis

A股量化 AkShare

mbpz
A股量化数据分析工具,基于AkShare库获取A股行情、财务数据、板块信息等。用于回答关于A股股票查询、行情数据、财务分析、选股等问题。
★ 166 📥 60,201