如何引用R语言以及R包:文献引用
2023-02-18 16:28:21 时间
数据分析中经常使用R语言以及相关R包,写文章时就需要引用。这里介绍两种方法。
1. 默认的citeation
函数
1.1 引用R语言
包括R版本和相关信息:
注意,函数中什么参数都不添加,会返回R语言的版本和相关信息。
citation()
> citation()
To cite R in publications use:
R Core Team (2022). R: A language and environment for statistical
computing. R Foundation for Statistical Computing, Vienna,
Austria. URL https://www.R-project.org/.
LaTeX的用户的BibTeX条目是
@Manual{,
title = {R: A Language and Environment for Statistical Computing},
author = {{R Core Team}},
organization = {R Foundation for Statistical Computing},
address = {Vienna, Austria},
year = {2022},
url = {https://www.R-project.org/},
}
We have invested a lot of time and effort in creating R, please
cite it when using it for data analysis. See also
‘citation("pkgname")’ for citing R packages.
提取相关信息,就是:
❝R Core Team (2022). R: A language and environment for statistical computing. R Foundation for Statistical Computing, Vienna, Austria. URL https://www.R-project.org/.12c ❞
1.2 引用具体R包
比如,这里想引用ggplot2
:
> citation("ggplot2")
To cite ggplot2 in publications, please use:
H. Wickham. ggplot2: Elegant Graphics for Data Analysis.
Springer-Verlag New York, 2016.
LaTeX的用户的BibTeX条目是
@Book{,
author = {Hadley Wickham},
title = {ggplot2: Elegant Graphics for Data Analysis},
publisher = {Springer-Verlag New York},
year = {2016},
isbn = {978-3-319-24277-4},
url = {https://ggplot2.tidyverse.org},
}
把里面的内容,提取出来,就是:
❝H. Wickham. ggplot2: Elegant Graphics for Data Analysis. Springer-Verlag New York, 2016. ❞
注意:如果R包没有在引号内,会报错:
> citation(ggplot2)
Error in system.file(package = package, lib.loc = lib.loc) :
object 'ggplot2' not found
2. 使用pacman
更友好的形式
2.1 R语言引用
「两种方法:」
- p_cite()
- p_citation()
library(pacman)
p_citation()
2.2 R包引用
「四种方法:」
具体的R包,可以直接写名称,也可以用引号包裹:
方法1:p_cite("ggplot2")
方法2:p_cite(ggplot2)
方法3:p_citation(ggplot2)
方法4:p_citation("ggplot2")
p_cite和p_citation都可以用,包的名称加不加引号都可以用,更人性化一点。
> p_cite("ggplot2")
To cite ggplot2 in publications, please use:
H. Wickham. ggplot2: Elegant Graphics for Data Analysis.
Springer-Verlag New York, 2016.
LaTeX的用户的BibTeX条目是
@Book{,
author = {Hadley Wickham},
title = {ggplot2: Elegant Graphics for Data Analysis},
publisher = {Springer-Verlag New York},
year = {2016},
isbn = {978-3-319-24277-4},
url = {https://ggplot2.tidyverse.org},
}
相关文章
- 制作乡镇地图数据
- 【二】Latex入门使用、常见指令
- 【CSDN浏览器插件测评超详细版】——万能便捷的C功能,直接爱不释手,强烈推荐!更多功能等你探索
- 常见多智能体强化学习仿真环境介绍【一】{推荐收藏,真的牛}
- ABAP之SM30触发数据附加功能
- 协程笔记
- 说明
- MOV.AI Flow 可视化ROS IDE
- 多智能体强化学习算法【一】【MAPPO、MADDPG、QMIX】
- 多智能体强化学习算法【二】【MADDPG、QMIX、MAPPO】
- 新项目决定用 JDK 17了
- 多智能体强化学习算法【三】【QMIX、MADDPG、MAPPO】
- 《吐血整理》高级系列教程-吃透Fiddler抓包教程(36)-掌握Fiddler中Fiddler Script用法,你会有多牛逼-上篇
- 《吐血整理》高级系列教程-吃透Fiddler抓包教程(37)-掌握Fiddler中Fiddler Script用法,你会有多牛逼-下篇
- 环境调试bug【一】
- 【Qbot】3.加入内容审核功能
- 环境调试bug【二】无法加载源“<string>”: Source unavailable
- parser.add_argument()用法——命令行选项、参数和子命令解析器
- 一次TiDB GC阻塞引发的性能问题分析
- windows共享文件创建----局域网办公