Checks if a DOI (Digital Object Identifier) has a good structure, i.e. 10.----/suffix. Also checks if the redirection using the DOI System (https://www.doi.org/) works. An internet connection is required.

check_doi(doi)

Arguments

doi

a character of length 1. A single DOI to check.

Value

A logical. If the DOI has the good structure and exists on https://www.doi.org/, the returned value will be TRUE.

Examples

check_doi("bad_doi")
#> [1] FALSE
check_doi("10.1016/j.jviromet.2032.01.007")
#> [1] FALSE
check_doi("10.1016/j.jviromet.2008.01.007")
#> [1] TRUE