Skip to content

Commit

Permalink
Fix education and add CRAN DOI
Browse files Browse the repository at this point in the history
  • Loading branch information
dieghernan committed Jun 14, 2024
1 parent c47b361 commit 2e91621
Show file tree
Hide file tree
Showing 21 changed files with 32 additions and 20 deletions.
4 changes: 2 additions & 2 deletions CITATION.cff
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ message: 'To cite package "giscoR" in publications use:'
type: software
license: GPL-3.0-only
title: 'giscoR: Download Map Data from GISCO API - Eurostat'
version: 0.5.0
version: 0.5.0.9000
doi: 10.32614/CRAN.package.giscoR
abstract: Tools to download data from the GISCO (Geographic Information System of
the Commission) Eurostat database <https://ec.europa.eu/eurostat/web/gisco>. Global
Expand All @@ -31,7 +31,7 @@ preferred-citation:
affiliation: rOpenGov
doi: 10.32614/CRAN.package.giscoR
year: '2024'
version: 0.5.0
version: 0.5.0.9000
url: https://ropengov.github.io/giscoR/
abstract: Tools to download data from the GISCO (Geographic Information System of
the Commission) Eurostat database <https://ec.europa.eu/eurostat/web/gisco>. Global
Expand Down
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Type: Package
Package: giscoR
Title: Download Map Data from GISCO API - Eurostat
Version: 0.5.0
Version: 0.5.0.9000
Authors@R: c(
person("Diego", "Hernangómez", , "[email protected]", role = c("aut", "cre", "cph"),
comment = c(ORCID = "0000-0001-8457-4658", affiliation = "rOpenGov")),
Expand Down
4 changes: 4 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# giscoR (development version)

- `gisco_get_education()`:Fix API entry points.

# giscoR 0.5.0

- New functions:
Expand Down
2 changes: 1 addition & 1 deletion R/gisco_get_education.R
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ gisco_get_education <- function(cache = TRUE, update_cache = FALSE,


api_entry <- paste0(
"https://gisco-services.ec.europa.eu/pub/education",
"https://gisco-services.ec.europa.eu/pub/education/2020/",
"/gpkg/", country_get, ".gpkg"
)

Expand Down
2 changes: 1 addition & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ results](https://badges.cranchecks.info/worst/giscoR.svg)](https://cran.r-projec
[![R-hub](https://github.com/rOpenGov/giscoR/actions/workflows/rhub.yaml/badge.svg)](https://github.com/rOpenGov/giscoR/actions/workflows/rhub.yaml)
[![codecov](https://codecov.io/gh/ropengov/giscoR/branch/main/graph/badge.svg)](https://app.codecov.io/gh/ropengov/giscoR)
[![CodeFactor](https://www.codefactor.io/repository/github/ropengov/giscor/badge)](https://www.codefactor.io/repository/github/ropengov/giscor)
[![DOI](https://img.shields.io/badge/DOI-10.5281/zenodo.4317946-blue)](https://doi.org/10.5281/zenodo.4317946)
[![DOI](https://img.shields.io/badge/DOI-10.32614/CRAN.package.giscoR-blue)](https://doi.org/10.32614/CRAN.package.giscoR)
[![Project Status:
Active](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active)

Expand Down
11 changes: 7 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ results](https://badges.cranchecks.info/worst/giscoR.svg)](https://cran.r-projec
[![R-hub](https://github.com/rOpenGov/giscoR/actions/workflows/rhub.yaml/badge.svg)](https://github.com/rOpenGov/giscoR/actions/workflows/rhub.yaml)
[![codecov](https://codecov.io/gh/ropengov/giscoR/branch/main/graph/badge.svg)](https://app.codecov.io/gh/ropengov/giscoR)
[![CodeFactor](https://www.codefactor.io/repository/github/ropengov/giscor/badge)](https://www.codefactor.io/repository/github/ropengov/giscor)
[![DOI](https://img.shields.io/badge/DOI-10.5281/zenodo.4317946-blue)](https://doi.org/10.5281/zenodo.4317946)
[![DOI](https://img.shields.io/badge/DOI-10.32614/CRAN.package.giscoR-blue)](https://doi.org/10.32614/CRAN.package.giscoR)
[![Project Status:
Active](https://www.repostatus.org/badges/latest/active.svg)](https://www.repostatus.org/#active)

Expand Down Expand Up @@ -68,6 +68,9 @@ install.packages("giscoR",

## Usage

You can have a look to the documentation of the dev version in
<https://ropengov.github.io/giscoR/dev/>

This script highlights some features of **giscoR** :

``` r
Expand Down Expand Up @@ -183,6 +186,7 @@ We now download the data from Eurostat:
library(eurostat)
popdens <- get_eurostat("demo_r_d3dens") %>%
filter(TIME_PERIOD == "2021-01-01")
#> indexed 0B in 0s, 0B/sindexed 1.00TB in 0s, 457.44TB/s
```

By last, we merge and manipulate the data for creating the final plot:
Expand Down Expand Up @@ -326,7 +330,7 @@ A BibTeX entry for LaTeX users is
doi = {10.32614/CRAN.package.giscoR},
author = {Diego Hernangómez},
year = {2024},
version = {0.5.0},
version = {0.5.0.9000},
url = {https://ropengov.github.io/giscoR/},
abstract = {Tools to download data from the GISCO (Geographic Information System of the Commission) Eurostat database <https://ec.europa.eu/eurostat/web/gisco>. Global and European map data available. This package is in no way officially related to or endorsed by Eurostat.},
}
Expand Down Expand Up @@ -360,8 +364,7 @@ This package is in no way officially related to or endorsed by Eurostat.

## References

<div id="refs" class="references csl-bib-body hanging-indent"
entry-spacing="0">
<div id="refs" class="references csl-bib-body hanging-indent">

<div id="ref-RJ-2017-019" class="csl-entry">

Expand Down
6 changes: 3 additions & 3 deletions codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@
"codeRepository": "https://github.com/rOpenGov/giscoR",
"issueTracker": "https://github.com/rOpenGov/giscoR/issues",
"license": "https://spdx.org/licenses/GPL-3.0",
"version": "0.5.0",
"version": "0.5.0.9000",
"programmingLanguage": {
"@type": "ComputerLanguage",
"name": "R",
"url": "https://r-project.org"
},
"runtimePlatform": "R version 4.4.0 (2024-04-24 ucrt)",
"runtimePlatform": "R version 4.4.0 (2024-04-24)",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
Expand Down Expand Up @@ -240,7 +240,7 @@
"applicationCategory": "cartography",
"isPartOf": "http://ropengov.org/",
"keywords": ["ropengov", "r", "spatial", "api-wrapper", "rstats", "r-package", "eurostat", "gisco", "thematic-maps", "eurostat-data", "cran", "ggplot2", "gis"],
"fileSize": "1259.642KB",
"fileSize": "1251.202KB",
"citation": [
{
"@type": "SoftwareSourceCode",
Expand Down
Binary file modified data/gisco_countrycode.rda
Binary file not shown.
Binary file modified data/gisco_db.rda
Binary file not shown.
Binary file modified img/README-example-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/README-example-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/README-labels-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified img/README-thematic-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 changes: 5 additions & 4 deletions inst/CITATION
Original file line number Diff line number Diff line change
@@ -1,13 +1,14 @@
year <- format(Sys.time(), "%Y")
abs <- trimws(gsub("\\s+", " ", meta$Description))
abs <- gsub("'", "", abs)
doi <- "10.5281/zenodo.4317946"
pkg <- meta$Package
doi <- paste0("10.32614/CRAN.package.", pkg)

bibentry(
"Manual",
header = paste0("To cite '", meta$Package, "' in publications use:"),
title = paste("{giscoR}:", gsub("'", "", meta$Title)),
doi = paste0("10.32614/CRAN.package.",meta$Package),
header = paste0("To cite '", pkg, "' in publications use:"),
title = paste0("{", pkg, "}: ", gsub("'", "", meta$Title)),
doi = doi,
author = c(person("Diego", "Hernangómez")),
year = year,
version = meta$Version,
Expand Down
4 changes: 2 additions & 2 deletions inst/schemaorg.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"runtimePlatform": "R version 4.4.0 (2024-04-24 ucrt)",
"version": "0.5.0"
"runtimePlatform": "R version 4.4.0 (2024-04-24)",
"version": "0.5.0.9000"
},
{
"id": "https://doi.org/10.32614/CRAN.package.giscoR",
Expand Down
2 changes: 1 addition & 1 deletion man/chunks/addressapi.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ Endpoints](https://gisco-services.ec.europa.eu/addressapi/docs/screen/endpoints)

| **Endpoint** | **Description** |
|-----------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `/countries` | Returns all country codes that are compatible with the address API. Check the coverage map for available countries and see [here for a list of official country codes](https://publications.europa.eu/code/en/en-5000500.htm). |
| `/countries` | Returns all country codes that are compatible with the address API. Check the coverage map for available countries and see [here for a list of official country codes](https://style-guide.europa.eu/en/content/-/isg/topic?identifier=annex-a5-list-countries-territories-currencies). |
| `/provinces` | Returns all provinces within the specified country. Can also be used to get the province of a specified city. |
| `/cities` | Returns all cities within a specified province or country. |
| `/roads` | Returns all roads or streets within a specified city. |
Expand Down
2 changes: 1 addition & 1 deletion man/gisco_addressapi.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file modified vignettes/africa-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified vignettes/country-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified vignettes/giscoR-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions vignettes/giscoR.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,10 @@ eu_bord <- borders %>%
# Eurostat data - Disposable income
pps <- get_eurostat("tgs00026") %>%
filter(TIME_PERIOD == "2021-01-01")
#> indexed 0B in 0s, 0B/sindexed 1.00TB in 0s, 4.17PB/s
```

``` r

nuts2_sf <- nuts2 %>%
left_join(pps, by = "geo") %>%
Expand Down

0 comments on commit 2e91621

Please sign in to comment.