Skip to content

Commit

Permalink
Merge pull request #22 from oggioniale/dev
Browse files Browse the repository at this point in the history
merge release 1.0.0
  • Loading branch information
oggioniale authored Nov 15, 2021
2 parents c77b78c + 1160224 commit 70bbcbd
Show file tree
Hide file tree
Showing 208 changed files with 12,362 additions and 4,145 deletions.
56 changes: 47 additions & 9 deletions DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,19 +1,55 @@
Package: ReLTER
Type: Package
Title: An interface to the eLTER for the R statistical programming environment
Version: 0.2.0
Date: 2021-10-19
Version: 1.0.0
Date: 2021-11-15
Authors@R: c(
person("Alessandro", "Oggioni", email = "[email protected]", role = c("aut", "cre", "fnd"),
person("Alessandro", "Oggioni", email = "[email protected]",
role = c("aut", "cre", "fnd"),
comment = c(ORCID = "0000-0002-7997-219X")
),
person("Paolo", "Tagliolato", email = "[email protected]", role = "ctb",
comment = c(ORCID = "0000-0002-0261-313X")
person("Micha", "Silver", email = "[email protected]",
role = c("aut", "ctb"),
comment = c(ORCID = "0000-0002-1128-1325",
" Micha Silver is a coauthor of functions get_ilter_generalinfo and
get_site_info for category Boundaries, he develop get_site_ODS
function and he also is a reviewer of English wording for all
functions.")
),
person("Paolo", "Tagliolato", email = "[email protected]",
role = c("aut", "ctb"),
comment = c(ORCID = "0000-0002-0261-313X",
" Paolo Tagliolato is a coauthor of package, he wrote the function
do_Q(), on which some ReLTER internal functions are based")
)
)
Maintainer: The package maintainer Alessandro Oggioni, phD (2020) <[email protected]>
Description: More about what it does (maybe more than one line)
Use four spaces when indenting paragraphs within the Description.
Maintainer: The package maintainer Alessandro Oggioni, phD (2020)
<[email protected]>
Description: ReLTER is an R package that: provides access to DEIMS-SDR
(https://deims.org/), allows interact with software implemented by eLTER
Research Infrastructure (RI) and improves the data/information shared by
them.
ReLTER is a R package devoted to access, interact and improve the
information and the data shared by Long Term Ecological Research (LTER)
network. This package is born within eLTER H2020 major project that will
help advance the development of European Long-Term Ecosystem Research
Infrastructures (eLTER RI - https://elter-ri.eu).
The ReLTER package functions in particular allow to:
- retrive the information about entities (e.g. sites, datasets, and
activities) shared by DEIMS-SDR (see e.g. get_site_info function);
- interact with the [ODSEurope](maps.opendatascience.eu) managed by members
of the [Geo-harmonizer](https://opendatascience.eu/geoharmonizer-project/)
project starting with the dataset shared by [DEIMS-SDR](https://deims.org/)
(see e.g. [get_site_ODS](https://oggioniale.github.io/ReLTER/reference/get_site_ODS.html)
function);
- use the site informations for download data from other platforms (see
e.g. get_site_ODS function);
- improve the quality of the dataset (see e.g. get_id_worms).
Functions currently implemented are derived from the discussion of the
needs declared by eLTER users community.
The ReLTER package shall definitely follow the progress of eLTER-RI
infrastructure and evolving with the improvements and develop of
new tools.
License: GPL-3
Encoding: UTF-8
LazyData: true
Expand All @@ -29,6 +65,7 @@ Imports:
rgeos (>= 0.5-3),
rosm (>= 0.2.5),
raster (>= 3.3-13),
terra (>= 1.4-11),
tmap (>= 3.1),
grid (>= 3.5.1),
leaflet (>= 2.0.3),
Expand All @@ -46,7 +83,6 @@ Imports:
xml2 (>= 1.3.2),
magrittr (>= 2.0.1),
stats (>= 4.0.3)
RoxygenNote: 7.1.1
Suggests:
testthat (>= 3.0.0),
knitr,
Expand All @@ -55,3 +91,5 @@ VignetteBuilder: knitr
URL: https://github.com/oggioniale/ReLTER
BugReports: https://github.com/oggioniale/ReLTER/issues
Config/testthat/edition: 3
RoxygenNote: 7.1.2
Language: en-GB
70 changes: 43 additions & 27 deletions NAMESPACE
Original file line number Diff line number Diff line change
@@ -1,39 +1,45 @@
# Generated by roxygen2: do not edit by hand

export(createQRCode)
export(getActivity)
export(getDataset)
export(getILTEREnvCharacts)
export(getILTERGeneralInfo)
export(getILTERParameters)
export(getILTERResearchTopics)
export(getNetworkEnvCharacts)
export(getNetworkParameters)
export(getNetworkRelatedResources)
export(getNetworkResearchTopics)
export(getNetworkSites)
export(getSOSProcedureList)
export(getSiteAffiliations)
export(getSiteBoundaries)
export(getSiteContact)
export(getSiteEnvCharacts)
export(getSiteGeneral)
export(getSiteInfrastructure)
export(getSiteParameters)
export(getSiteRelatedResources)
export(getSiteResearchTopics)
export(mapNetworkPoint)
export(parametersChartPie)
export(parametersChartWaffle)
export(produceMapOfSiteFromDEIMS)
export(taxonIDPesi)
export(get_activity_info)
export(get_dataset_info)
export(get_ilter_envcharacts)
export(get_ilter_generalinfo)
export(get_ilter_parameters)
export(get_ilter_research_topics)
export(get_network_envcharacts)
export(get_network_parameters)
export(get_network_related_resources)
export(get_network_research_topics)
export(get_network_sites)
export(get_site_ODS)
export(get_site_affiliations)
export(get_site_boundaries)
export(get_site_contact)
export(get_site_envcharacts)
export(get_site_general)
export(get_site_info)
export(get_site_infrastructure)
export(get_site_parameters)
export(get_site_related_resources)
export(get_site_research_topics)
export(get_sos_procedurelist)
export(produce_network_points_map)
export(produce_site_map)
export(produce_site_parameters_pie)
export(produce_site_parameters_waffle)
export(produce_site_qrcode)
export(taxon_id_pesi)
export(taxon_id_worms)
export(taxon_id_worms_refine)
import(ISOcodes)
importFrom(RColorBrewer,brewer.pal)
importFrom(dplyr,as_tibble)
importFrom(dplyr,bind_rows)
importFrom(dplyr,case_when)
importFrom(dplyr,distinct)
importFrom(dplyr,filter)
importFrom(dplyr,group_by)
importFrom(dplyr,left_join)
importFrom(dplyr,mutate)
importFrom(dplyr,select)
importFrom(dplyr,tally)
Expand Down Expand Up @@ -61,6 +67,7 @@ importFrom(leaflet,addMarkers)
importFrom(leaflet,addPolygons)
importFrom(leaflet,addTiles)
importFrom(leaflet,leaflet)
importFrom(magrittr,"%>%")
importFrom(mapview,mapshot)
importFrom(qrcode,qrcode_gen)
importFrom(raster,getData)
Expand All @@ -74,9 +81,17 @@ importFrom(sf,st_as_sf)
importFrom(sf,st_as_sfc)
importFrom(sf,st_bbox)
importFrom(sf,st_crs)
importFrom(sf,st_transform)
importFrom(sf,st_write)
importFrom(sf,write_sf)
importFrom(stringr,str_detect)
importFrom(taxize,eubon_search)
importFrom(terra,crop)
importFrom(terra,crs)
importFrom(terra,mask)
importFrom(terra,plot)
importFrom(terra,rast)
importFrom(terra,vect)
importFrom(tibble,as_tibble)
importFrom(tibble,tribble)
importFrom(tmap,tm_basemap)
Expand All @@ -93,6 +108,7 @@ importFrom(tmap,tm_shape)
importFrom(utils,capture.output)
importFrom(utils,data)
importFrom(waffle,waffle)
importFrom(worrms,wm_records_names)
importFrom(xml2,read_xml)
importFrom(xml2,xml_find_all)
importFrom(xml2,xml_ns)
20 changes: 20 additions & 0 deletions NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,23 @@
## ReLTER 1.0.0 Release Notes

v1.0.0 was released on 15/11/2021

### Major changes

* all the getSite* functions could be merged into one, with an additional function parameter category;
* all the functions are renamed according with CRAN suggestion;
* first release of vignettes have been done;
* new functions for interactive improvements of taxa names using PESI and WORMS repository have been done;
* function acquires one of eight raster datasets from the European OpenDataScience maps website for a selected DEIMS site have been implemented by @micha-silver;
* a fully review of functions and package description have been done.

### Minor changes

* CITATION file are been created;
* this version has been submitted on rOpenSci.

________________________________________________________________________________

## ReLTER 0.2.0 Release Notes

v0.2.0 was released on 18/10/2021
Expand Down
2 changes: 1 addition & 1 deletion R/do_Q.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#' @title eLTER do_Q function
#' @description This function ...
#' @description This function parses json content returned from an HTTP request
#' @param q a character
#' @param jj a character
#' @return The output of the function is ...
Expand Down
66 changes: 0 additions & 66 deletions R/getILTERGeneralInfo.R

This file was deleted.

22 changes: 10 additions & 12 deletions R/getActivity.R → R/get_activity_info.R
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
#' @title eLTER getActivity function
#' @description This function allows to obtain the info of activity (actually
#' only title) provided in DEIMS-SDR.
#' @param activityid A character. It is the DEIMS iD of activity make from
#' @title eLTER get_activity_info function
#' @description This function obtains the info of activity (actually
#' title) provided in DEIMS-SDR.
#' @param activityid A character. The DEIMS activity ID from
#' DEIMS-SDR website. More information about DEIMS iD in this
#' \href{https://deims.org/docs/deimsid.html}{page}.
#' @return The output of the function is a `tibble` with main features of
#' the activity make in a site.
#' the activities in a site, and a `leaflet` map plot.
#' @author Alessandro Oggioni, phD (2020) \email{oggioni.a@@irea.cnr.it}
#' @importFrom httr GET content
#' @importFrom dplyr as_tibble
#' @importFrom utils capture.output
#' @importFrom sf st_as_sf
#' @importFrom leaflet leaflet addTiles addPolygons
#' @importFrom rgeos gIsValid
#' @importFrom magrittr %>%
#' @export
#' @examples
#' activities <- getActivity(activityid = "https://deims.org/activity/8786fc6d-5d70-495c-b901-42f480182845")
#' activities <- get_activity_info(activityid = "https://deims.org/activity/8786fc6d-5d70-495c-b901-42f480182845")
#' map <- leaflet::leaflet(activities) %>%
#' leaflet::addTiles() %>%
#' leaflet::addPolygons()
#' print(map)
#' activities
#'
### function getActivity
getActivity <- function(activityid) {
require(dplyr)
### function get_activity_info
get_activity_info <- function(activityid) {
q <- "{
title: .title,
boundaries: .attributes.geographic.boundaries
Expand Down Expand Up @@ -86,9 +86,7 @@ getActivity <- function(activityid) {
map <- NULL
}
} else {
message("\n---- The requested page could not be found. Please check again the Activity.iD ----\n")
geoActivity <- NULL
map <- NULL
stop("\n---- Page Not Found. The requested page could not be found. Please check again the Activity.iD ----\n")
}
print(map)
geoActivity
Expand Down
12 changes: 6 additions & 6 deletions R/getDataset.R → R/get_dataset_info.R
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
#' @title eLTER getDataset function
#' @title eLTER get_dataset_info function
#' @description This function allows to obtain the info of dataset provided in
#' DEIMS-SDR.
#' @param datasetid A character. It is the DEIMS iD of dataset make from
Expand All @@ -12,18 +12,18 @@
#' @importFrom utils capture.output
#' @importFrom sf st_as_sf
#' @importFrom leaflet leaflet addTiles addPolygons
#' @importFrom magrittr %>%
#' @export
#' @examples
#' tDataset <- getDataset(datasetid = "https://deims.org/dataset/38d604ef-decb-4d67-8ac3-cc843d10d3ef")
#' tDataset <- get_dataset_info(datasetid = "https://deims.org/dataset/38d604ef-decb-4d67-8ac3-cc843d10d3ef")
#' map <- leaflet::leaflet(tDataset) %>%
#' leaflet::addTiles() %>%
#' leaflet::addPolygons()
#' print(map)
#' tDataset
#'
### function getDataset
getDataset <- function(datasetid) {
require(dplyr)
### function get_dataset_info
get_dataset_info <- function(datasetid) {
q <- '{
title: .title,
abstract: .attributes.general.abstract,
Expand Down Expand Up @@ -105,7 +105,7 @@ getDataset <- function(datasetid) {
geoDataset_SP <- sf::as_Spatial(
geoDataset$boundaries
)
geoDataset_valid <- gIsValid(
geoDataset_valid <- rgeos::gIsValid(
geoDataset_SP,
byid = FALSE,
reason = TRUE
Expand Down
Loading

0 comments on commit 70bbcbd

Please sign in to comment.