From 2f17bf126f08ee17eadb5580734cd486c836667b Mon Sep 17 00:00:00 2001 From: Bruce Date: Mon, 21 Aug 2023 07:45:19 +0100 Subject: [PATCH] updated pkg info --- R/ChineseNames.R | 41 ++++--------------- README.md | 7 ++-- ...hineseNames.Rd => ChineseNames-package.Rd} | 21 +++++----- man/compute_name_index.Rd | 12 ------ 4 files changed, 22 insertions(+), 59 deletions(-) rename man/{ChineseNames.Rd => ChineseNames-package.Rd} (75%) diff --git a/R/ChineseNames.R b/R/ChineseNames.R index 84b3b93..e6293d4 100644 --- a/R/ChineseNames.R +++ b/R/ChineseNames.R @@ -25,23 +25,12 @@ #' This database was provided by Beijing Meiming Science and Technology Company (in collaboration) and #' originally obtained from the National Citizen Identity Information Center (NCIIC) of China in 2008. #' -#' @section Citation: -#' Bao, H.-W.-S. (2023). ChineseNames: Chinese Name Database 1930-2008. -#' R package version 2023.8. -#' \url{https://CRAN.R-project.org/package=ChineseNames} -#' -#' Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). -#' Novel evidence for the increasing prevalence of unique names in China: -#' A reply to Ogihara. \emph{Frontiers in Psychology, 12}, 731244. -#' \doi{10.3389/fpsyg.2021.731244} -#' -#' @docType package -#' @name ChineseNames -NULL +"_PACKAGE" .onAttach = function(libname, pkgname) { inst.ver = as.character(utils::packageVersion("ChineseNames")) + pkg.date = substr(utils::packageDate("ChineseNames"), 1, 4) packageStartupMessage(glue::glue_col(" {magenta ChineseNames (v{inst.ver})} @@ -51,17 +40,11 @@ NULL {underline https://psychbruce.github.io/ChineseNames} {magenta To use this package in publications, please cite:} - - "), - "\n", - "Bao, H.-W.-S. (2023). ", - "ChineseNames: Chinese Name Database 1930-2008. ", - "R package version 2023.8. ", - "https://CRAN.R-project.org/package=ChineseNames\n", - "\n", - "Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). ", - "Novel evidence for the increasing prevalence of unique names in China: ", - "A reply to Ogihara. Frontiers in Psychology, 12, 731244.\n") + Bao, H.-W.-S. ({pkg.date}). "), + glue::glue_col("{italic ChineseNames: Chinese Name Database 1930-2008}"), + glue::glue_col(" (Version {inst.ver}) [Computer software]. "), + glue::glue_col("{underline https://CRAN.R-project.org/package=ChineseNames}"), + "\n") } @@ -210,16 +193,6 @@ NULL #' @note #' For details and examples, see \url{https://psychbruce.github.io/ChineseNames/} #' -#' @section Citation: -#' Bao, H.-W.-S. (2023). ChineseNames: Chinese Name Database 1930-2008. -#' R package version 2023.8. -#' \url{https://CRAN.R-project.org/package=ChineseNames} -#' -#' Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). -#' Novel evidence for the increasing prevalence of unique names in China: -#' A reply to Ogihara. \emph{Frontiers in Psychology, 12}, 731244. -#' \doi{10.3389/fpsyg.2021.731244} -#' #' @examples #' ## Prepare ## #' sn = familyname$surname[1:12] diff --git a/README.md b/README.md index 2e9f9e1..f92f640 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,7 @@ A database of Chinese surnames and Chinese given names (1930-2008). This databas -[![CRAN-Version](https://www.r-pkg.org/badges/version/ChineseNames?color=red)](https://CRAN.R-project.org/package=ChineseNames) [![GitHub-Version](https://img.shields.io/github/r-package/v/psychbruce/ChineseNames?label=GitHub&color=orange)](https://github.com/psychbruce/ChineseNames) [![R-CMD-check](https://github.com/psychbruce/ChineseNames/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/psychbruce/ChineseNames/actions/workflows/R-CMD-check.yaml) [![CRAN-Downloads](https://cranlogs.r-pkg.org/badges/grand-total/ChineseNames)](https://CRAN.R-project.org/package=ChineseNames) [![Logo-Designer](https://img.shields.io/badge/Logo%20Designer-Meijia%20Li-blueviolet?logo=github-sponsors)](https://github.com/Stellapros) [![GitHub-Stars](https://img.shields.io/github/stars/psychbruce/ChineseNames?style=social)](https://github.com/psychbruce/ChineseNames/stargazers) +[![CRAN-Version](https://www.r-pkg.org/badges/version/ChineseNames?color=red)](https://CRAN.R-project.org/package=ChineseNames) [![GitHub-Version](https://img.shields.io/github/r-package/v/psychbruce/ChineseNames?label=GitHub&color=orange)](https://github.com/psychbruce/ChineseNames) [![R-CMD-check](https://github.com/psychbruce/ChineseNames/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/psychbruce/ChineseNames/actions/workflows/R-CMD-check.yaml) [![CRAN-Downloads](https://cranlogs.r-pkg.org/badges/grand-total/ChineseNames)](https://CRAN.R-project.org/package=ChineseNames) [![GitHub-Stars](https://img.shields.io/github/stars/psychbruce/ChineseNames?style=social)](https://github.com/psychbruce/ChineseNames/stargazers) @@ -22,8 +22,9 @@ Han-Wu-Shuang (Bruce) Bao 包寒吴霜 ## Citation -- Bao, H.-W.-S. (2023). *ChineseNames: Chinese Name Database 1930-2008*. R package version 2023.8. -- Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). Novel evidence for the increasing prevalence of unique names in China: A reply to Ogihara. *Frontiers in Psychology, 12*, 731244. +- Bao, H.-W.-S. (2023). *ChineseNames: Chinese Name Database 1930-2008* (Version 2023.8) [Computer software]. +- Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). Novel evidence for the increasing prevalence of unique names in China: A reply to Ogihara. *Frontiers in Psychology, 12*, Article 731244. +- Bao, H.-W.-S., Lu, H., & Luo, Y. L. L. (in press). Do unique names fit people for creative work? Implications for job recruitment, name change, and product evaluation. *European Journal of Social Psychology*. ## Installation diff --git a/man/ChineseNames.Rd b/man/ChineseNames-package.Rd similarity index 75% rename from man/ChineseNames.Rd rename to man/ChineseNames-package.Rd index bf8c24a..21d4ce6 100644 --- a/man/ChineseNames.Rd +++ b/man/ChineseNames-package.Rd @@ -1,8 +1,9 @@ % Generated by roxygen2: do not edit by hand % Please edit documentation in R/ChineseNames.R \docType{package} -\name{ChineseNames} +\name{ChineseNames-package} \alias{ChineseNames} +\alias{ChineseNames-package} \title{ChineseNames: Chinese Name Database 1930-2008} \source{ This database was provided by Beijing Meiming Science and Technology Company (in collaboration) and @@ -29,15 +30,15 @@ This database does not contain any individual-level information All data are at the name level or character level. Extremely rare characters are not included. } -\section{Citation}{ - -Bao, H.-W.-S. (2023). ChineseNames: Chinese Name Database 1930-2008. -R package version 2023.8. -\url{https://CRAN.R-project.org/package=ChineseNames} +\seealso{ +Useful links: +\itemize{ + \item \url{https://psychbruce.github.io/ChineseNames/} + \item Report bugs at \url{https://github.com/psychbruce/ChineseNames/issues} +} -Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). -Novel evidence for the increasing prevalence of unique names in China: -A reply to Ogihara. \emph{Frontiers in Psychology, 12}, 731244. -\doi{10.3389/fpsyg.2021.731244} } +\author{ +\strong{Maintainer}: Han-Wu-Shuang Bao \email{baohws@foxmail.com} (\href{https://orcid.org/0000-0003-3043-710X}{ORCID}) +} diff --git a/man/compute_name_index.Rd b/man/compute_name_index.Rd index 4db024f..d7815d1 100644 --- a/man/compute_name_index.Rd +++ b/man/compute_name_index.Rd @@ -93,18 +93,6 @@ is estimated by forecasting and thereby may not be accurate. \note{ For details and examples, see \url{https://psychbruce.github.io/ChineseNames/} } -\section{Citation}{ - -Bao, H.-W.-S. (2023). ChineseNames: Chinese Name Database 1930-2008. -R package version 2023.8. -\url{https://CRAN.R-project.org/package=ChineseNames} - -Bao, H.-W.-S., Cai, H., Jing, Y., & Wang, J. (2021). -Novel evidence for the increasing prevalence of unique names in China: -A reply to Ogihara. \emph{Frontiers in Psychology, 12}, 731244. -\doi{10.3389/fpsyg.2021.731244} -} - \examples{ ## Prepare ## sn = familyname$surname[1:12]