GenderGuesser

An R package for using the genderize.io API to guess the gender of names.
git clone https://git.eamoncaddigan.net/GenderGuesser.git
Log | Files | Refs | README | LICENSE

commit 5dfaa6bee6e01de4b281473467e0d052d58883b9
parent 05795756db58f3b6787c3f06f7b0ff5269f928b7
Author: eamoncaddigan <eamon.caddigan@gmail.com>
Date:   Sun,  9 Aug 2015 15:10:54 -0400

Handling missing results better.

Diffstat:
MR/guessGender.R | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/R/guessGender.R b/R/guessGender.R @@ -19,7 +19,7 @@ checkLanguageCountryCodes <- function(countryCode, languageCode) { #' is requested, otherwise returns the element itself. #' @keywords internal getListElement <- function(listName, elementName) { - if (match(elementName, names(listName), nomatch = 0) > 0) { + if (!is.null(listName[[elementName]])) { listElement <- listName[[elementName]] } else { listElement <- NA