Skip to content

Commit a1cb587

Browse files
committed
Ported the CITATION to the new "API".
1 parent 664c2c7 commit a1cb587

File tree

2 files changed

+50
-49
lines changed

2 files changed

+50
-49
lines changed

DESCRIPTION

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
Package: ergm.rank
2-
Version: 1.1.0-1303
3-
Date: 2018-07-21
2+
Version: 1.1.0-1306
3+
Date: 2018-08-25
44
Title: Fit, Simulate and Diagnose Exponential-Family Models for Rank-Order Relational Data
55
Authors@R: c(
66
person("Pavel N.", "Krivitsky", role=c("aut","cre"), email="[email protected]"),

inst/CITATION

Lines changed: 48 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -1,47 +1,48 @@
1-
# ---- BEGIN STATNET CITATION FUNCTIONS ----
2-
# A header function for ensuring that all the statnet packages provide consistent messaging
3-
statnet.cite.head <- function(pkg){
4-
citHeader(
5-
paste("`",pkg,"` is part of the Statnet suite of packages. ",
6-
"If you are using the `",pkg,"` package for research that will be published, ",
7-
"we request that you acknowledge this by citing the following.\n",
8-
'For BibTeX format, use toBibtex(citation("',pkg,'")).',
9-
sep="")
10-
)
11-
}
12-
13-
# A footer function for ensuring that all the statnet packages provide consistent messaging
14-
statnet.cite.foot <- function(pkg){
15-
# the 'meta' variable is be provided by R's CITATION processing script
16-
citFooter("We have invested a lot of time and effort in creating the",
17-
"Statnet suite of packages for use by other researchers.",
18-
"Please cite it in all papers where it is used. The package",pkg," is made distributed under the terms of the license:",meta$License )
19-
}
20-
21-
# generates a consistent bibentry citation for the software manual of the package
22-
statnet.cite.pkg <- function(pkg=NULL){
23-
if(!is.null(pkg)){
24-
meta <- try(utils::packageDescription(pkg))
25-
if(inherits(meta,"try-error") || is.na(meta)) return()
26-
}
27-
# the 'meta' variable is provided by R's CITATION processing script
28-
projhomepage <- "http://www.statnet.org"
29-
# compute the list of authors
30-
auts <- eval(parse(text=meta$`Authors@R`))
31-
auts <- auts[sapply(auts, function(aut) "aut" %in% aut$role)]
32-
# create a citation entry for a "software manual" for this version of the software
33-
# it will be appended with any specific articles defineded inthe package citation file
34-
bibentry("Manual",
35-
author = auts,
36-
title = paste(meta$Package,": ", meta$Title, sep=""),
37-
organization = paste("The Statnet Project (\\url{", projhomepage, "})",sep=""),
38-
year = substr(meta$Date,1,4),
39-
note = paste("R package version ", meta$Version, sep=""),
40-
url = paste("https://CRAN.R-project.org/package=",meta$Package,sep="")
41-
)
42-
}
43-
# ---- END STATNET CITATION FUNCTIONS ----'
44-
statnet.cite.head("ergm.rank")
45-
statnet.cite.pkg()
46-
statnet.cite.pkg("ergm")
47-
statnet.cite.foot("ergm.rank")
1+
#' statnet: statnet.cite.head("ergm.rank")
2+
# ---- BEGIN AUTOGENERATED STATNET CITATION ----
3+
citHeader(paste0(sQuote("ergm.rank"), " is part of the Statnet suite of packages. ",
4+
"If you are using the ", sQuote("ergm.rank"), " package for research that will be published, ",
5+
"we request that you acknowledge this by citing the following.\n",
6+
"For BibTeX format, use toBibtex(citation(\"", "ergm.rank",
7+
"\"))."))
8+
# ---- END AUTOGENERATED STATNET CITATION ----
9+
#' statnet: statnet.cite.pkg("ergm.rank")
10+
# ---- BEGIN AUTOGENERATED STATNET CITATION ----
11+
bibentry("Manual", author = structure(list(list(given = "Pavel N.",
12+
family = "Krivitsky", role = c("aut", "cre"), email = "[email protected]",
13+
comment = NULL)), class = "person"), title = paste("ergm.rank",
14+
": ", "Fit, Simulate and Diagnose Exponential-Family Models for Rank-Order Relational Data",
15+
sep = ""), organization = paste("The Statnet Project (\\url{",
16+
"http://www.statnet.org", "})", sep = ""), year = substr("2018-08-25",
17+
1, 4), note = paste("R package version ", "1.1.0-1306", sep = ""),
18+
url = paste("https://CRAN.R-project.org/package=", "ergm.rank",
19+
sep = ""))
20+
# ---- END AUTOGENERATED STATNET CITATION ----
21+
#' statnet: statnet.cite.pkg("ergm")
22+
# ---- BEGIN AUTOGENERATED STATNET CITATION ----
23+
bibentry("Manual", author = structure(list(list(given = "Mark S.",
24+
family = "Handcock", role = "aut", email = "[email protected]",
25+
comment = NULL), list(given = "David R.", family = "Hunter",
26+
role = "aut", email = "[email protected]", comment = NULL),
27+
list(given = "Carter T.", family = "Butts", role = "aut",
28+
email = "[email protected]", comment = NULL), list(given = "Steven M.",
29+
family = "Goodreau", role = "aut", email = "[email protected]",
30+
comment = NULL), list(given = "Pavel N.", family = "Krivitsky",
31+
role = c("aut", "cre"), email = "[email protected]", comment = c(ORCID = "0000-0002-9101-3362")),
32+
list(given = "Martina", family = "Morris", role = "aut",
33+
email = "[email protected]", comment = NULL)), class = "person"),
34+
title = paste("ergm", ": ", "Fit, Simulate and Diagnose Exponential-Family Models for\nNetworks",
35+
sep = ""), organization = paste("The Statnet Project (\\url{",
36+
"http://www.statnet.org", "})", sep = ""), year = substr("2018-08-15",
37+
1, 4), note = paste("R package version ", "3.9.4", sep = ""),
38+
url = paste("https://CRAN.R-project.org/package=", "ergm",
39+
sep = ""))
40+
# ---- END AUTOGENERATED STATNET CITATION ----
41+
#' statnet: statnet.cite.foot("ergm.rank")
42+
# ---- BEGIN AUTOGENERATED STATNET CITATION ----
43+
citFooter(paste0("We have invested a lot of time and effort in creating the ",
44+
"Statnet suite of packages for use by other researchers. ",
45+
"Please cite it in all papers where it is used. The package ",
46+
sQuote("ergm.rank"), " is distributed under the terms of the license ",
47+
"GPL-3 + file LICENSE", "."))
48+
# ---- END AUTOGENERATED STATNET CITATION ----

0 commit comments

Comments
 (0)