Science Score: 13.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (12.1%) to scientific vocabulary
Keywords
jerico-relevant
marine
peer-reviewed
r
r-package
rstats
spatial
Last synced: 4 months ago
·
JSON representation
Repository
MarineRegions R client
Basic Info
- Host: GitHub
- Owner: ropensci-archive
- License: other
- Language: HTML
- Default Branch: master
- Homepage: https://docs.ropensci.org/mregions
- Size: 6.68 MB
Statistics
- Stars: 16
- Watchers: 8
- Forks: 6
- Open Issues: 0
- Releases: 3
Archived
Topics
jerico-relevant
marine
peer-reviewed
r
r-package
rstats
spatial
Created about 10 years ago
· Last pushed over 1 year ago
Metadata Files
Readme
Changelog
License
Codemeta
README-NOT.Rmd
---
output: github_document
---
mregions
========
```{r setup, include=FALSE}
knitr::opts_chunk$set(
warning = FALSE,
message = FALSE,
collapse = TRUE,
comment = "#>"
)
```
[](https://app.travis-ci.com/ropensci/mregions)
[](https://app.codecov.io/github/ropensci/mregions?branch=master)
[](https://github.com/r-hub/cranlogs.app)
[](https://cran.r-project.org/package=mregions)
[](https://github.com/ropensci/software-review/issues/53)
`mregions` - Get data from
Some data comes from the [Flanders Marine Institute (VLIZ) geoserver](http://geo.vliz.be/geoserver/web/)
`mregions` is useful to a wide diversity of R users because you get access to all of the
data MarineRegions has, which can help in a variety of use cases:
* Visualize marine regions alone
* Visualize marine regions with associated data paired with analysis
* Use marine region geospatial boundaries to query data providers (e.g., OBIS ())
* Geocode - get geolocation data from place names
* Reverse Geocode - get place names from geolocation data
## Install
```{r eval=FALSE}
install.packages("mregions")
install.packages("sf")
```
Development version
```{r eval=FALSE}
devtools::install_github("ropensci/mregions")
```
Load Libraries
```{r}
library("mregions")
library("sf")
# helper library
library("leaflet")
```
## Get GeoJSON
#### example 1: Marine Ecoregions of the World (MEOW)
**Get Data**
Keys accessible from the [Flanders Marine Institute (VLIZ) geoserver](http://geo.vliz.be/geoserver/web/).
```{r, eval=TRUE}
ecoregions_geoJSON <- mr_geojson(key = "Ecoregions:ecoregions", maxFeatures = 250)
length(ecoregions_geoJSON$features)
```
**Plot Data**
```{r eval=FALSE}
leaflet() %>%
addProviderTiles(provider = 'OpenStreetMap') %>%
addGeoJSON(geojson = ecoregions_geoJSON$features) %>%
fitBounds(-160,-52,160,60)
```

### example 2: Maritime Boundaries (EEZ)
**Get Data**
```{r}
eezboundaries_geoJSON <- mr_geojson(key = "MarineRegions:eez", maxFeatures = 1)
```
**Plot Data**
```{r eval=FALSE}
leaflet() %>%
addProviderTiles(provider = 'OpenStreetMap') %>%
addGeoJSON(geojson = eezboundaries_geoJSON$features) %>%
fitBounds(39,11,83,-10)
```

## Get Shape
#### example 1: Marine Ecoregions of the World (MEOW)
**Select region**
```{r, eval=TRUE}
ecoregions_shp <- mr_shp(key = "Ecoregions:ecoregions", maxFeatures = 250)
class(ecoregions_shp)
```
**Plot data**
```{r eval=FALSE}
leaflet() %>%
addProviderTiles(provider = 'OpenStreetMap') %>%
addPolygons(data = ecoregions_shp)%>%
fitBounds(-182,-79,178,83)
```

#### example 2: Maritime Boundaries (EEZ)
**Select region**
```{r, eval=FALSE}
eezboundaries_shp <- mr_shp(key = "MarineRegions:eez", maxFeatures = 1)
```
**Plot data**
```{r eval=FALSE}
leaflet() %>%
addProviderTiles(provider = 'OpenStreetMap') %>%
addPolygons(data = eezboundaries_shp)
```

## Convert to WKT
#### example 1: Marine Ecoregions of the World (MEOW)
**From GeoJSON**
```{r eval=TRUE}
ecoregions_geoJSON <- mr_geojson(key = "Ecoregions:ecoregions", maxFeatures = 250)
ecoregions_wkt_fromGeoJSON <- mr_as_wkt(ecoregions_geoJSON, fmt = 2)
class(ecoregions_wkt_fromGeoJSON)
ecoregions_wkt_fromGeoJSON[1]
```
**From shp object (using the sf package)**
```{r eval=TRUE}
ecoregions_shp <- mr_shp(key = "Ecoregions:ecoregions", maxFeatures = 250)
ecoregions_shp_geom <- st_geometry(ecoregions_shp)
ecoregions_wkt_fromshp <- st_as_text(ecoregions_shp_geom)
ecoregions_wkt_fromshp[1]
```
*More detailed example using the Black Sea Ecoregion only*
```{r, eval=TRUE}
ecoregions_blacksea <- subset(ecoregions_shp, ecoregions_shp$ecoregion == "Black Sea")
class(ecoregions_blacksea)
ecoregions_blacksea_geom <- st_geometry(ecoregions_blacksea)
class(ecoregions_blacksea_geom)
ecoregions_blacksea_wkt <- st_as_text(ecoregions_blacksea_geom)
class(ecoregions_blacksea_wkt)
ecoregions_blacksea_wkt
```
## Gazetteer Record by Name
#### example: High Seas
```{r, eval=TRUE}
highseas_info <- mr_geo_code(place = "High Seas")
class(highseas_info)
str(highseas_info)
```
## Contributors
* [Scott Chamberlain](https://github.com/sckott)
* [Francois Michonneau](https://github.com/fmichonneau)
* [Pieter Provoost](https://github.com/pieterprovoost)
* [Michael Sumner](https://github.com/mdsumner)
* [Lennert Schepers](https://github.com/LennertSchepers)
* [Salvador Fernandez](https://github.com/salvafern)
## Meta
* Please [report any issues or bugs](https://github.com/ropensci/mregions/issues).
* License: MIT
* Get citation information for `mregions` in R doing `citation(package = 'mregions')`
* Please note that this project is released with a [Contributor Code of Conduct](https://github.com/ropensci/mregions/blob/master/CONDUCT.md). By participating in this project you agree to abide by its terms.
[](https://ropensci.org)
Owner
- Name: rOpenSci Archive
- Login: ropensci-archive
- Kind: organization
- Email: info@ropensci.org
- Website: ropensci.org
- Repositories: 259
- Profile: https://github.com/ropensci-archive
Abandoned rOpenSci projects -- email info@ropensci.org if you have questions!
CodeMeta (codemeta.json)
{
"@context": "https://doi.org/10.5063/schema/codemeta-2.0",
"@type": "SoftwareSourceCode",
"identifier": "mregions",
"description": "Tools to get marine regions data from <https://www.marineregions.org/>. Includes tools to get region metadata, as well as data in 'GeoJSON' format, as well as Shape files. Use cases include using data downstream to visualize 'geospatial' data by marine region, mapping variation among different regions, and more.",
"name": "mregions: Marine Regions Data from 'Marineregions.org'",
"relatedLink": "https://docs.ropensci.org/mregions/",
"codeRepository": "https://github.com/ropensci/mregions",
"issueTracker": "https://github.com/ropensci/mregions/issues",
"license": "https://spdx.org/licenses/MIT",
"version": "0.1.9",
"programmingLanguage": {
"@type": "ComputerLanguage",
"name": "R",
"url": "https://r-project.org"
},
"runtimePlatform": "R version 4.3.2 (2023-10-31)",
"author": [
{
"@type": "Person",
"givenName": "Scott",
"familyName": "Chamberlain"
},
{
"@type": "Person",
"givenName": "Lennert",
"familyName": "Schepers"
},
{
"@type": "Person",
"givenName": "Salvador",
"familyName": "Fernandez",
"email": "salvador.fernandez@vliz.be"
}
],
"contributor": [
{
"@type": "Person",
"givenName": "Francois",
"familyName": "Michonneau"
},
{
"@type": "Person",
"givenName": "Pieter",
"familyName": "Provoost"
},
{
"@type": "Person",
"givenName": "Michael",
"familyName": "Sumner"
}
],
"maintainer": [
{
"@type": "Person",
"givenName": "Salvador",
"familyName": "Fernandez",
"email": "salvador.fernandez@vliz.be"
}
],
"softwareSuggestions": [
{
"@type": "SoftwareApplication",
"identifier": "roxygen2",
"name": "roxygen2",
"version": ">= 6.0.1",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=roxygen2"
},
{
"@type": "SoftwareApplication",
"identifier": "testthat",
"name": "testthat",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=testthat"
},
{
"@type": "SoftwareApplication",
"identifier": "knitr",
"name": "knitr",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=knitr"
},
{
"@type": "SoftwareApplication",
"identifier": "rmapshaper",
"name": "rmapshaper",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=rmapshaper"
}
],
"softwareRequirements": {
"1": {
"@type": "SoftwareApplication",
"identifier": "utils",
"name": "utils"
},
"2": {
"@type": "SoftwareApplication",
"identifier": "httr",
"name": "httr",
"version": ">= 1.1.0",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=httr"
},
"3": {
"@type": "SoftwareApplication",
"identifier": "jsonlite",
"name": "jsonlite",
"version": ">= 1.0",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=jsonlite"
},
"4": {
"@type": "SoftwareApplication",
"identifier": "xml2",
"name": "xml2",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=xml2"
},
"5": {
"@type": "SoftwareApplication",
"identifier": "rappdirs",
"name": "rappdirs",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=rappdirs"
},
"6": {
"@type": "SoftwareApplication",
"identifier": "sp",
"name": "sp",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=sp"
},
"7": {
"@type": "SoftwareApplication",
"identifier": "sf",
"name": "sf",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=sf"
},
"8": {
"@type": "SoftwareApplication",
"identifier": "data.table",
"name": "data.table",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=data.table"
},
"9": {
"@type": "SoftwareApplication",
"identifier": "tibble",
"name": "tibble",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=tibble"
},
"10": {
"@type": "SoftwareApplication",
"identifier": "geojsonio",
"name": "geojsonio",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=geojsonio"
},
"11": {
"@type": "SoftwareApplication",
"identifier": "geojson",
"name": "geojson",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=geojson"
},
"12": {
"@type": "SoftwareApplication",
"identifier": "geojsonsf",
"name": "geojsonsf",
"provider": {
"@id": "https://cran.r-project.org",
"@type": "Organization",
"name": "Comprehensive R Archive Network (CRAN)",
"url": "https://cran.r-project.org"
},
"sameAs": "https://CRAN.R-project.org/package=geojsonsf"
},
"SystemRequirements": null
},
"fileSize": "3629.778KB",
"releaseNotes": "https://github.com/ropensci/mregions/blob/main/NEWS.md",
"readme": "https://github.com/ropensci/mregions/blob/master/README.md",
"contIntegration": [
"https://travis-ci.org/ropensci/mregions",
"https://codecov.io/github/ropensci/mregions?branch=master"
],
"review": {
"@type": "Review",
"url": "https://github.com/ropensci/software-review/issues/53",
"provider": "https://ropensci.org"
},
"keywords": [
"rstats",
"r",
"marine",
"spatial",
"r-package",
"peer-reviewed",
"jerico-relevant"
]
}
GitHub Events
Total
- Watch event: 1
Last Year
- Watch event: 1
Dependencies
DESCRIPTION
cran
- leaflet * enhances
- data.table * imports
- geojson * imports
- geojsonio * imports
- geojsonsf * imports
- httr >= 1.1.0 imports
- jsonlite >= 1.0 imports
- rappdirs * imports
- sf * imports
- sp * imports
- tibble * imports
- utils * imports
- xml2 * imports
- knitr * suggests
- rgdal * suggests
- rgeos * suggests
- rmapshaper * suggests
- roxygen2 >= 6.0.1 suggests
- testthat * suggests