{"id":38654533,"url":"https://github.com/openwashdata/boreholefuncmwi","last_synced_at":"2026-01-17T09:25:38.674Z","repository":{"id":245408325,"uuid":"818155581","full_name":"openwashdata/boreholefuncmwi","owner":"openwashdata","description":"Data about the survey on the borehole functionality in Karonga district, Malawi.","archived":false,"fork":false,"pushed_at":"2024-06-27T18:39:20.000Z","size":644,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2024-06-28T18:10:12.365Z","etag":null,"topics":["borehole","malawi","opendata","openwashdata","r","survey-data"],"latest_commit_sha":null,"homepage":"https://openwashdata.github.io/boreholefuncmwi/","language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc-by-4.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/openwashdata.png","metadata":{"files":{"readme":"README.Rmd","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2024-06-21T08:08:19.000Z","updated_at":"2024-06-27T18:39:23.000Z","dependencies_parsed_at":"2024-06-22T01:56:39.997Z","dependency_job_id":"d55f7e2d-b331-4411-9393-0d03d2b323f2","html_url":"https://github.com/openwashdata/boreholefuncmwi","commit_stats":null,"previous_names":["openwashdata/boreholefuncmwi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/openwashdata/boreholefuncmwi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/openwashdata%2Fboreholefuncmwi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/openwashdata%2Fboreholefuncmwi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/openwashdata%2Fboreholefuncmwi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/openwashdata%2Fboreholefuncmwi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/openwashdata","download_url":"https://codeload.github.com/openwashdata/boreholefuncmwi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/openwashdata%2Fboreholefuncmwi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28505550,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-17T06:57:29.758Z","status":"ssl_error","status_checked_at":"2026-01-17T06:56:03.931Z","response_time":85,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["borehole","malawi","opendata","openwashdata","r","survey-data"],"created_at":"2026-01-17T09:25:38.006Z","updated_at":"2026-01-17T09:25:38.646Z","avatar_url":"https://github.com/openwashdata.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput: github_document\nalways_allow_html: true\neditor_options: \n  markdown: \n    wrap: 72\n  chunk_output_type: console\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  message = FALSE,\n  warning = FALSE,\n  fig.retina = 2,\n  fig.align = 'center'\n)\n```\n\n# boreholefuncmwi\n\n\u003c!-- badges: start --\u003e\n\n[![License: CC BY\n4.0](https://img.shields.io/badge/License-CC_BY_4.0-lightgreen.svg)](https://creativecommons.org/licenses/by/4.0/)\n[![R-CMD-check](https://github.com/openwashdata/boreholefuncmwi/actions/workflows/R-CMD-check.yaml/badge.svg)](https://github.com/openwashdata/boreholefuncmwi/actions/workflows/R-CMD-check.yaml)\n[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.12635354.svg)](https://zenodo.org/doi/10.5281/zenodo.12635354)\n\u003c!-- badges: end --\u003e\n\nThe goal of `boreholefuncmwi` is to provide access to data which were collected in the Karonga district (North of Malawi) and contains answers from a 20-minute questionnaire about boreholes. The questionnaire was installed on [koboToolbox](www.kobotoolbox.org) to collect borehole functionality data from 300 respondents aged 18 and above.\n\n## Installation\n\nYou can install the development version of boreholefuncmwi from\n[GitHub](https://github.com/) with:\n\n``` r\n# install.packages(\"devtools\")\ndevtools::install_github(\"openwashdata/boreholefuncmwi\")\n```\n\n```{r}\n## Run the following code in console if you don't have the packages\n## install.packages(c(\"dplyr\", \"knitr\", \"readr\", \"stringr\", \"gt\", \"kableExtra\"))\nlibrary(dplyr)\nlibrary(knitr)\nlibrary(readr)\nlibrary(stringr)\nlibrary(gt)\nlibrary(kableExtra)\n```\n\nAlternatively, you can download the individual datasets as a CSV or XLSX\nfile from the table below.\n\n```{r, echo=FALSE, message=FALSE, warning=FALSE}\n\nextdata_path \u003c- \"https://github.com/openwashdata/boreholefuncmwi/raw/main/inst/extdata/\"\n\nread_csv(\"data-raw/dictionary.csv\") |\u003e \n  distinct(file_name) |\u003e \n  dplyr::mutate(file_name = str_remove(file_name, \".rda\")) |\u003e \n  dplyr::rename(dataset = file_name) |\u003e \n  mutate(\n    CSV = paste0(\"[Download CSV](\", extdata_path, dataset, \".csv)\"),\n    XLSX = paste0(\"[Download XLSX](\", extdata_path, dataset, \".xlsx)\")\n  ) |\u003e \n  knitr::kable()\n\n```\n\n## Data\n\n```{r}\nlibrary(boreholefuncmwi)\n```\n\n### boreholefuncmwi\n\nThe dataset `boreholefuncmwi` contains data about borehole's management in the North of Malawi. Questions included in the questionnaire are for example about the borehole maintenance contributions from the community, the availability of borehole spare parts, tariff collection frequency and presence of a service provider.\nIt has `r nrow(boreholefuncmwi)` observations and `r ncol(boreholefuncmwi)` variables.\n\n```{r}\nboreholefuncmwi |\u003e \n  head(3) |\u003e \n  gt::gt() |\u003e\n  gt::as_raw_html()\n```\n\nFor an overview of the variable names, see the following table.\n\n```{r echo=FALSE, message=FALSE, warning=FALSE}\nreadr::read_csv(\"data-raw/dictionary.csv\") |\u003e\n  dplyr::filter(file_name == \"boreholefuncmwi.rda\") |\u003e\n  dplyr::select(variable_name:description) |\u003e \n  knitr::kable() |\u003e \n  kableExtra::kable_styling(\"striped\") |\u003e \n  kableExtra::scroll_box(height = \"200px\")\n```\n\n\n## Example\n\nIt can be interesting to analyse the numbers of households who draw water from a borehole in each village. Here is a plot showing the distribution of boreholes' use across villages.\n\n```{r}\nlibrary(boreholefuncmwi)\nlibrary(unhcrthemes)\nlibrary(ggplot2)\nborehole_user \u003c- boreholefuncmwi %\u003e%\n  group_by(village) %\u003e%\n  summarise(number_households = sum(number_households, na.rm = TRUE))\n\nggplot(borehole_user) +\n  geom_col(aes(\n    x = number_households,\n    y = reorder(village, number_households)\n  ),\n  fill = \"lightgreen\",  # Change the color here to light green\n  width = 0.8\n  ) +\n  geom_text(aes(\n    x = number_households,\n    y = reorder(village, number_households),\n    label = round(number_households)\n  ),\n  hjust = -0.5,\n  size = 8 / .pt\n  ) +\n  labs(\n    title = \"Number of households using a borehole\",\n    caption = \"Boreholes distribution according to villages\"\n    \n  ) +\n  scale_x_continuous(expand = expansion(c(0, 0.1))) +\n  theme_unhcr(\n    grid = FALSE,\n    axis = \"y\",\n    axis_title = FALSE,\n    axis_text = \"y\"\n  )\n```\n\n## Capstone Project\n\nThis dataset is shared as part of a capstone project in [Data Science for openwashdata](https://ds4owd-001.github.io/website/). For more information about the project and to explore further insights, please visit the project page at \u003chttps://ds4owd-001.github.io/project-myesaya/\u003e\n\n## License\n\nData are available as\n[CC-BY](https://github.com/openwashdata/boreholefuncmwi/blob/main/LICENSE.md).\n\n## Citation\n\nPlease cite this package using:\n\n```{r}\ncitation(\"boreholefuncmwi\")\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenwashdata%2Fboreholefuncmwi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fopenwashdata%2Fboreholefuncmwi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fopenwashdata%2Fboreholefuncmwi/lists"}