Skip to content

Commit

Permalink
Merge pull request #1 from rempsyc/master
Browse files Browse the repository at this point in the history
updated vignette and readme with format_publications function issue jkeirstead#110
  • Loading branch information
GuangchuangYu committed Aug 9, 2022
2 parents 19d243a + 4c7d9f5 commit 2f4564a
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 2 deletions.
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,10 +59,22 @@ compare_scholar_careers(ids)

## Predicting future h-index values

Finally users can predict the future [h-index](http://en.wikipedia.org/wiki/H-index) of a scholar, based on the method of [Acuna et al.](https://www.nature.com/nature/articles/489201a). Since the method was originally calibrated on data from neuroscientists, it goes without saying that, if the scholar is from another discipline, then the results should be taken with a large pinch of salt. A more general critique of the original paper is available [here](http://simplystatistics.org/2012/10/10/whats-wrong-with-the-predicting-h-index-paper/). Still, it's a bit of fun.
Users can predict the future [h-index](http://en.wikipedia.org/wiki/H-index) of a scholar, based on the method of [Acuna et al.](https://www.nature.com/nature/articles/489201a). Since the method was originally calibrated on data from neuroscientists, it goes without saying that, if the scholar is from another discipline, then the results should be taken with a large pinch of salt. A more general critique of the original paper is available [here](http://simplystatistics.org/2012/10/10/whats-wrong-with-the-predicting-h-index-paper/). Still, it's a bit of fun.

```
## Predict h-index of original method author, Daniel Acuna
id <- 'GAi23ssAAAAJ'
predict_h_index(id)
```

## Formatting publications for CV

Finally, the `format_publications` function can be used (e.g., in conjunction with the [`vitae`](https://pkg.mitchelloharawild.com/vitae/) package) to format publications in APA Style. The short name of the author of interest (e.g., of the person whose CV is being made) can be highlighted in bold with the `author.name` argument. The function after the pipe allows rmarkdown to format them properly, and the code chunk should be set to `results = "asis"`.

```
# APA style:
format_publications("NrfwEncAAAAJ", "R Thériault") |> cat(sep='\n\n')
# Numbering format:
format_publications("NrfwEncAAAAJ", "R Thériault") |> print(quote=FALSE)
```
20 changes: 19 additions & 1 deletion vignettes/scholar.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ id <- 'B7vSqZsAAAAJ'
## Get his profile
l <- get_profile(id)
## Print his name and affliation
## Print his name and affiliation
l$name
l$affiliation
Expand Down Expand Up @@ -94,6 +94,7 @@ ggplot(ach, aes(year, cites)) +
```

# Comparing scholars

You can compare the citation history of scholars by fetching data with
`compare_scholars`.
```{r}
Expand Down Expand Up @@ -132,3 +133,20 @@ plot_coauthors(coauthor_network)
```

Note however, that these are the coauthors listed in Google Scholar profile and not coauthors from all publications.

# Formatting publications for CV

The `format_publications` function can be used for example in conjunction with the [`vitae`](https://pkg.mitchelloharawild.com/vitae/) package to format publications in APA Style. The short name of the author of interest (e.g., of the person whose CV is being made) can be highlighted in bold with the `author.name` argument. The function after the pipe allows rmarkdown to format them properly, and the code chunk should be set to `results = "asis"`.

### APA style

```{r results = "asis"}
format_publications("NrfwEncAAAAJ", "R Thériault") |> cat(sep='\n\n')
```

### Numbering format

```{r results = "asis"}
format_publications("NrfwEncAAAAJ", "R Thériault") |> print(quote=FALSE)
```

0 comments on commit 2f4564a

Please sign in to comment.