{"id":16960200,"url":"https://github.com/markkvdb/ghor","last_synced_at":"2025-09-23T14:21:10.045Z","repository":{"id":113964106,"uuid":"229352685","full_name":"markkvdb/ghoR","owner":"markkvdb","description":"R interface for the GHO API of the WHO","archived":false,"fork":false,"pushed_at":"2020-02-26T21:56:07.000Z","size":135,"stargazers_count":1,"open_issues_count":4,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-04T08:40:00.130Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/markkvdb.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-12-20T23:50:29.000Z","updated_at":"2021-02-08T09:39:41.000Z","dependencies_parsed_at":null,"dependency_job_id":"65e1330a-5e51-4f79-9549-4083809f857c","html_url":"https://github.com/markkvdb/ghoR","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/markkvdb/ghoR","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/markkvdb%2FghoR","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/markkvdb%2FghoR/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/markkvdb%2FghoR/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/markkvdb%2FghoR/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/markkvdb","download_url":"https://codeload.github.com/markkvdb/ghoR/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/markkvdb%2FghoR/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":276588553,"owners_count":25668906,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-23T02:00:09.130Z","response_time":73,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-13T22:47:31.733Z","updated_at":"2025-09-23T14:21:10.028Z","avatar_url":"https://github.com/markkvdb.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput: github_document\n---\n\n\u003c!-- README.md is generated from README.Rmd. Please edit that file --\u003e\n\n```{r, include = FALSE}\nknitr::opts_chunk$set(\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"man/figures/README-\",\n  out.width = \"100%\"\n)\n```\n\n# ghoR\n\n\u003c!-- badges: start --\u003e\n[![Travis build status](https://travis-ci.org/markkvdb/ghoR.svg?branch=master)](https://travis-ci.org/markkvdb/ghoR)\n[![Codecov test coverage](https://codecov.io/gh/markkvdb/ghoR/branch/master/graph/badge.svg)](https://codecov.io/gh/markkvdb/ghoR?branch=master)\n\u003c!-- badges: end --\u003e\n\nThe ghoR package can be used to conventiently load data from the GHO portal of the WHO. The GHO database contains over 20,000 *indicators* which represent a statistic on a country level.\n\n## Installation\n\nYou can install the released version of ghoR from [CRAN](https://CRAN.R-project.org) with:\n\n``` r\ninstall.packages(\"ghoR\")\n```\n\nAnd the development version from [GitHub](https://github.com/) with:\n\n``` r\n# install.packages(\"devtools\")\ndevtools::install_github(\"markkvdb/ghoR\")\n```\n## Example\n\nIf you are not sure yet which indicator you would like to explore you can discover all indicators by loading it into a dataframe. To prevent downloading the dataset every time you request a dataset, the dataset is saved in `~/.ghoR/`. This file is only updated if the WHO website shows that the dataset is last updated after downloading our local version of the dataset.\n\n```{r example-load}\n# First load the library and kable to present table\nlibrary(ghoR)\nset.seed(420)\n\n# Get a table of all indicators with the code and description.\nindicators \u003c- show_GHO_indicators()\nindicators_sample \u003c- dplyr::sample_n(indicators, 10)\n\nknitr::kable(indicators_sample)\n```\n\nAs an example, we will look at the remaining life expectancy from age $x$ for all available countries, years, sexes and ages. We can load this data using\n\n```{r example-indicator}\nex_data \u003c- read_GHO_data(\"LIFE_0000000035\")\n\nknitr::kable(head(ex_data, 10))\n```\n\n## Tidying dataset\n\nDatasets downloaded from the WHO website do not follow the tidy philosophy. For the spatial, time and other dimensions, each dimension has a column for the unit of the dimension and one for the value. Most users prefer having their datasets ready for analysis. The `ghoR` package provides a function to transform the dataset as\n\n```{r example-tidy}\ntidy_data \u003c- tidy_data(ex_data)\n\nknitr::kable(head(tidy_data, 10))\n```\n\n## Updating Datasets\n\nTo prevent downloading the dataset every time you request a dataset, the dataset is saved in `~/.ghoR/`. This file is only updated if the WHO website shows that the last update date is after the last updated date of the downloaded dataset on the user's computer.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarkkvdb%2Fghor","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmarkkvdb%2Fghor","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmarkkvdb%2Fghor/lists"}