Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add generic field extraction function #75

Open
3 tasks
katrinleinweber opened this issue May 2, 2018 · 0 comments
Open
3 tasks

Add generic field extraction function #75

katrinleinweber opened this issue May 2, 2018 · 0 comments

Comments

@katrinleinweber
Copy link
Collaborator

katrinleinweber commented May 2, 2018

The BacDive example and my vignette have some demo code for a temp extraction. It would be neat to have a search function for specific "paths" within the returned (large) list of lists. For example: retrieve_field('geo') should return environment_sampling_isolation_source$origin$geo_loc_name

Similar example: extracting specific fields: https://github.com/EngqvistLab/fetch_microbial_growth_temperatures/blob/159c411ff12578a6ac7b45e95d661558caccc2ea/BacDive/1_BacDive_get_data.py#L204-L223

Things to check:

  • dumping str() into a file and extracting the path from there
  • something to extract a tree representation from the nested dataframes
  • or try jsonlite::flatten()

related to #95

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant