erdos_number: erdos number

Description Usage Arguments Details Value Examples

Description

A function to crawl the co-author tree looking for matches

Usage

1
erdos_number(myname, target = "Erdos", cutoff = 2)

Arguments

myname

name as character with two elements, forename and surname

target

the name to match

cutoff

stop trying after going this number of levels deep

Details

This is really just an example function showing how the RMendeley functions can leverage the power of scripted codes and the R language to perform arbitrary & complicated data manipulation.

Value

the erdos number and the network of coauthors The network is a list, where each element is successively farther removed

Examples

1
2
3
4
5
## Not run: 
a <- erdos_number(myname=c(forename='Carl', surname='Boettiger'),
 target=c(forename='Simon', surname='Levin'), cutoff=3)

## End(Not run)

ropensci/RMendeley documentation built on May 27, 2019, 2:03 p.m.