MCP HubMCP Hub
스킬 목록으로 돌아가기

format-apa-report

pjt222
업데이트됨 Yesterday
5 조회
17
2
17
GitHub에서 보기
디자인general

정보

이 스킬은 Quarto 또는 R Markdown 보고서를 APA 7판 기준에 맞춰 서식을 지정합니다. apaquarto 또는 papaja 패키지를 사용하여 표지, 초록, 인용, 표, 그림 및 참고문헌을 자동화합니다. 심리학 및 사회과학 분야에서 재현 가능한 학술 원고를 생성할 때 활용하세요.

빠른 설치

Claude Code

추천
기본
npx skills add pjt222/agent-almanac -a claude-code
플러그인 명령대체
/plugin add https://github.com/pjt222/agent-almanac
Git 클론대체
git clone https://github.com/pjt222/agent-almanac.git ~/.claude/skills/format-apa-report

Claude Code에서 이 명령을 복사하여 붙여넣어 스킬을 설치하세요

문서


name: format-apa-report description: > 按照 APA 第7版格式编排 Quarto 或 R Markdown 报告。涵盖 apaquarto/papaja 包、扉页、摘要、引用、表格、图表和参考文献格式。适用于撰写 APA 格式的学术 论文、创建心理学或社会科学研究报告、生成嵌入分析的可复现手稿,或准备学位 论文章节。 license: MIT allowed-tools: Read Write Edit Bash Grep Glob metadata: author: Philipp Thoss version: "1.0" domain: reporting complexity: intermediate language: R tags: apa, academic, psychology, quarto, papaja locale: zh-CN source_locale: en source_commit: 6f65f316 translator: claude-sonnet-4-6 translation_date: 2026-03-16

格式化 APA 报告

使用 Quarto(apaquarto)或 R Markdown(papaja)创建 APA 第7版格式的报告。

适用场景

  • 撰写 APA 格式的学术论文
  • 创建心理学或社会科学研究报告
  • 生成嵌入分析的可复现手稿
  • 准备学位论文章节

输入

  • 必需:分析代码和结果
  • 必需:参考文献文件(.bib)
  • 可选:合著者和单位信息
  • 可选:手稿类型(期刊文章、学生论文)

步骤

第 1 步:选择框架

选项 A:apaquarto(Quarto,推荐)

install.packages("remotes")
remotes::install_github("wjschne/apaquarto")

选项 B:papaja(R Markdown)

remotes::install_github("crsh/papaja")

预期结果: 所选框架包成功安装,可通过 library(apaquarto)library(papaja) 加载。

失败处理: 如果因缺少系统依赖项(如 PDF 输出的 LaTeX)导致安装失败,请先使用 quarto install tinytex 安装 TinyTeX。如果 GitHub 安装失败,检查 remotes 包是否已安装且 GitHub 可访问。

第 2 步:创建文档(apaquarto)

创建 manuscript.qmd

---
title: "Effects of Variable X on Outcome Y"
shorttitle: "Effects of X on Y"
author:
  - name: First Author
    corresponding: true
    orcid: 0000-0000-0000-0000
    email: [email protected]
    affiliations:
      - name: University Name
        department: Department of Psychology
  - name: Second Author
    affiliations:
      - name: Other University
abstract: |
  This study examined the relationship between X and Y.
  Using a sample of N = 200 participants, we found...
  Results are discussed in terms of theoretical implications.
keywords: [keyword1, keyword2, keyword3]
bibliography: references.bib
format:
  apaquarto-docx: default
  apaquarto-pdf:
    documentmode: man
---

预期结果: 文件 manuscript.qmd 存在,包含有效的 YAML 前言部分,含标题、短标题、作者单位、摘要、关键词、参考文献引用和 APA 特定格式选项。

失败处理: 确认 YAML 缩进一致(2个空格),author: 条目使用包含 name:affiliations:corresponding: 字段的列表格式。检查 bibliography: 指向现有的 .bib 文件。

第 3 步:撰写 APA 内容

# Introduction

Previous research has established that... [@smith2023; @jones2022].
@smith2023 found significant effects of X on Y.

# Method

## Participants

We recruited `r nrow(data)` participants (*M*~age~ = `r mean(data$age)`,
*SD* = `r sd(data$age)`).

## Materials

The study used the Measurement Scale [@author2020].

## Procedure

Participants completed... (see @fig-design for the study design).

# Results

```{r}
#| label: fig-results
#| fig-cap: "Mean scores by condition with 95% confidence intervals."
#| fig-width: 6
#| fig-height: 4

ggplot(summary_data, aes(x = condition, y = mean, fill = condition)) +
  geom_col() +
  geom_errorbar(aes(ymin = ci_lower, ymax = ci_upper), width = 0.2) +
  theme_apa()
```

A two-way ANOVA revealed a significant main effect of condition,
*F*(`r anova_result$df1`, `r anova_result$df2`) = `r anova_result$F`,
*p* `r format_pvalue(anova_result$p)`, $\eta^2_p$ = `r anova_result$eta`.

# Discussion

The findings support the hypothesis that...

# References

预期结果: 内容遵循 APA 章节结构(引言、方法、结果、讨论、参考文献),使用行内 R 代码报告统计数据,并使用 @fig-@tbl- 前缀进行正确的交叉引用。

失败处理: 如果行内 R 代码未渲染,请检查反引号-r 语法是否正确(`r expression`)。如果交叉引用显示为纯文本,检查引用的块标签是否使用了正确的前缀,以及块是否有相应的标题选项。

第 4 步:以 APA 样式格式化表格

#| label: tbl-descriptives
#| tbl-cap: "Descriptive Statistics by Condition"

library(gt)

descriptive_table <- data |>
  group_by(condition) |>
  summarise(
    M = mean(score),
    SD = sd(score),
    n = n()
  )

gt(descriptive_table) |>
  fmt_number(columns = c(M, SD), decimals = 2) |>
  cols_label(
    condition = "Condition",
    M = "*M*",
    SD = "*SD*",
    n = "*n*"
  )

预期结果: 表格以 APA 格式渲染:统计符号使用斜体列标题、正确的小数对齐和表格上方的描述性标题。

失败处理: 如果 gt 表格未以 APA 样式渲染,确保 gt 包已安装,cols_label() 使用 Markdown 风格斜体(*M**SD*)。papaja 用户应使用 apa_table() 而非 gt()

第 5 步:管理引用

创建 references.bib

@article{smith2023,
  author = {Smith, John A. and Jones, Mary B.},
  title = {Effects of intervention on outcomes},
  journal = {Journal of Psychology},
  year = {2023},
  volume = {45},
  pages = {123--145},
  doi = {10.1000/example}
}

APA 引用样式:

  • 括号引用:[@smith2023] -> (Smith & Jones, 2023)
  • 叙述引用:@smith2023 -> Smith and Jones (2023)
  • 多引用:[@smith2023; @jones2022] -> (Jones, 2022; Smith & Jones, 2023)

预期结果: references.bib 包含有效的 BibTeX 条目,具备所有必需字段(author、title、year、journal),引用键与手稿文本中使用的一致。

失败处理: 使用在线验证器或 bibtool -d references.bib 验证 BibTeX 语法。确保文本中的引用键与 .bib 键完全匹配(区分大小写)。

第 6 步:渲染

# Word 文档(期刊投稿常用)
quarto render manuscript.qmd --to apaquarto-docx

# PDF(预印本或审稿用)
quarto render manuscript.qmd --to apaquarto-pdf

预期结果: 格式正确的 APA 文档,包含扉页、页眉和正确格式化的参考文献部分。

失败处理: PDF 渲染失败时,验证 TinyTeX 已安装(quarto install tinytex)。DOCX 输出问题请检查 apaquarto 的 Word 模板是否可访问。如果参考文献未显示,确保文档末尾有 # References 标题。

验证清单

  • 扉页格式正确(标题、作者、单位、作者注)
  • 包含摘要和关键词
  • 正文引用与参考文献列表匹配
  • 表格和图表编号正确
  • 统计数据按 APA 格式排版(斜体、正确符号)
  • 参考文献采用 APA 第7版格式
  • 页码和页眉存在(PDF)

常见问题

  • 行内 R 代码格式:使用反引号-r 语法报告行内统计数据,不要硬编码数值
  • 引用键不匹配:确保 .bib 键在文本中完全匹配
  • 图表放置:APA 手稿通常将图表放在末尾;设置 documentmode: man
  • 缺少 CSL 文件:apaquarto 内含 APA CSL;papaja 用户可能需要指定 csl: apa.csl
  • 摘要中的特殊字符:避免在 YAML 摘要块中使用 Markdown 格式

相关技能

  • create-quarto-report - 通用 Quarto 文档创建
  • generate-statistical-tables - 出版级表格
  • build-parameterized-report - 批量报告生成

GitHub 저장소

pjt222/agent-almanac
경로: i18n/zh-CN/skills/format-apa-report
0
agentsagentskillsai-assisted-developmentclaude-codeskillsteams

연관 스킬

executing-plans

디자인

executing-plans 스킬은 검토 체크포인트가 포함된 통제된 배치로 실행할 완전한 구현 계획이 있을 때 사용합니다. 이 스킬은 계획을 불러와 비판적으로 검토한 후, 소규모 배치(기본값 3개 작업)로 작업을 실행하면서 각 배치 사이에 진행 상황을 아키텍트 검토를 위해 보고합니다. 이를 통해 내재된 품질 관리 체크포인트를 갖춘 체계적인 구현이 보장됩니다.

스킬 보기

requesting-code-review

디자인

이 스킬은 코드 변경 사항을 요구 사항에 따라 분석하기 위해 코드 리뷰어 하위 에이전트를 호출합니다. 작업 완료 후, 주요 기능 구현 후, 또는 메인 브랜치에 병합하기 전에 사용해야 합니다. 이 리뷰는 현재 구현체와 원래 계획을 비교하여 문제를 조기에 발견하는 데 도움이 됩니다.

스킬 보기

connect-mcp-server

디자인

이 스킬은 개발자들이 HTTP, stdio 또는 SSE 전송 방식을 통해 MCP 서버를 Claude Code에 연결하는 포괄적인 가이드를 제공합니다. GitHub, Notion 및 사용자 정의 API와 같은 외부 서비스를 통합하기 위한 설치, 구성, 인증 및 보안을 다룹니다. MCP 통합 설정, 외부 도구 구성 또는 Claude의 모델 컨텍스트 프로토콜 작업 시 활용하세요.

스킬 보기

web-cli-teleport

디자인

이 스킬은 작업 분석을 기반으로 개발자가 Claude Code 웹 인터페이스와 CLI 인터페이스 중 선택할 수 있도록 돕고, 두 환경 간 원활한 세션 텔레포트를 가능하게 합니다. 웹, CLI 또는 모바일 환경 전환 시 세션 상태와 컨텍스트를 관리하여 워크플로를 최적화합니다. 다양한 단계에서 서로 다른 도구가 필요한 복잡한 프로젝트에 사용하세요.

스킬 보기