ropensci / neotoma

Programmatic R interface to the Neotoma Paleoecological Database.
https://docs.ropensci.org/neotoma
Other
30 stars 16 forks source link

`get_publications()` returns many empty columns #31

Closed gavinsimpson closed 10 years ago

gavinsimpson commented 11 years ago

As referenced in #29 get_publications() can return a large number of columns, many of which are empty for many rows because a single publication with many authors sets the upper limit on the number of columns in the Author data returned, and all other publications are expanded to match.

29 proposed to alter get_publications() so that it returned a list with two components instead of the single data frame that is currently returned.

The two components would be:

  1. publications; a data frame with components PublicationID, PubType, Year, and Citation.
  2. authors; a data frame in long (melted) format that contained the Authors.ContactName, Authors.ContactID, and Authors.Order information, plus a column with the PublicationID to match with the other publications component.
SimonGoring commented 10 years ago

I fixed this by replacing the output with a list of two data.frames in commit https://github.com/ropensci/neotoma/commit/d6be3cfe585fdfa82a9ea284dd7b971298bf82fc