authordown

English README: README.md
鍦ㄧ嚎搴旂敤锛歔鎵撳紑搴旂敤](https://zh1peng-authordown.share.connect.posit.cloud/)
authordown
鏄竴涓敤浜庣鐞嗕綔鑰呬俊鎭苟鐢熸垚璁烘枃鍓嶇疆淇℃伅锛堝挨鍏舵槸澶у瀷浣滆€呭垪琛ㄩ鍚嶉〉锛夌殑
R 鍖呫€?
鍔熻兘
- 棰樺悕椤电敓鎴愶紙鏈烘瀯缂栧彿銆侀€氳浣滆€呮爣璁帮級
- 浣滆€呬俊鎭牎楠屼笌鏍囧噯鍖?
- 鑷磋阿銆佸埄鐩婂啿绐佷笌浣滆€呰础鐚儴鍒?
- 鏍囧噯妯℃澘锛岀粺涓€浣滆€呮暟鎹綍鍏?
- Shiny 搴旂敤鐢ㄤ簬蹇€熼瑙堜笌瀵煎嚭
瀹夎
CRAN锛堝彂甯冨悗锛夛細
install.packages("authordown")
GitHub锛?
# install.packages("devtools")
devtools::install_github("zh1peng/authordown")
绔埌绔祦绋嬶紙绂荤嚎鍙敤锛?
1) 浠庡唴缃ā鏉垮紑濮?
library(authordown)
# 使用临时文件模板
template_path <- authordown_template()
authors <- authordown_read_local(template_path)
2) 鐢熸垚棰樺悕椤碉紙鏄剧ず瀛︿綅锛?
title_page <- generate_title_page(
data = authors,
title = "Example Paper",
style = "default",
show_degree = TRUE
)
cat(title_page)
3) 鐢熸垚鍏朵粬閮ㄥ垎
ack <- generate_acknowledgement(authors, style = "paragraph")
coi <- generate_conflict(authors, style = "paragraph")
contrib <- generate_contribution(authors, style = "bullets")
cat(ack)
cat("\n\n")
cat(coi)
cat("\n\n")
cat(contrib)
4) XLSX 杈撳叆
xlsx_path <- system.file("extdata", "authordown_template.xlsx", package = "authordown")
authors_xlsx <- authordown_read_local(xlsx_path)
鍦ㄧ嚎琛ㄦ牸鎺ㄨ崘娴佺▼
濡傛灉浣犲湪鍦ㄧ嚎琛ㄦ牸涓淮鎶や綔鑰呬俊鎭紝寤鸿瀵煎嚭鍒版湰鍦板悗鍐嶈鍙栵細
- 瀵煎嚭涓?CSV 鎴?XLSX锛堜篃鍙?TSV锛?
- 浣跨敤
authordown_read_local() 璇诲彇鏈湴鏂囦欢
鏀寔鏍煎紡锛欳SV銆乀SV銆乆LSX銆?
鏈烘瀯淇℃伅锛圓ffiliations锛?
浣跨敤 Affiliation1, Affiliation2, …
AffiliationN 鍒楀~鍐欏悓涓€浣滆€呯殑澶氫釜鏈烘瀯銆?
娌℃湁纭笂闄愶紝闇€瑕佸灏戝垪灏辨坊鍔犲灏戝垪銆傞鍚嶉〉浼氭寜棣栨鍑虹幇鐨勯『搴忕紪鍙枫€?
娓叉煋 HTML 浠ヤ究澶嶅埗绮樿创
濡傛灉闇€瑕佹覆鏌撳悗鐨?HTML
渚夸簬绮樿创鍒版姇绋跨郴缁燂紝鍙娇鐢細
if (requireNamespace("rmarkdown", quietly = TRUE) && rmarkdown::pandoc_available()) {
template_path <- authordown_template()
authors <- authordown_read_local(template_path)
html_path <- render_section_html(
section_title = "Conflict of Interest",
content_function = generate_conflict,
data = authors,
style = "paragraph"
)
# utils::browseURL(html_path)
}
甯歌闂
- 鈥淢issing required
column鈥?琛ㄧず鏂囦欢缂哄皯蹇呭~鍒楋紙濡?
FirstName銆乣LastName`锛夈€?
- 鈥淐orresponding authors must have an Email鈥?琛ㄧず瀛樺湪
Corresponding = TRUE 浣?Email 涓虹┖銆?
- 鈥淥RCID values must use the 0000-0000-0000-0000 format鈥?琛ㄧず
ORCID 鏍煎紡閿欒銆?