metaclipR.DatasetSubset: Directed metadata graph construction for DatasetSubsets

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

Build a directed metadata graph from climate4R grids that are subsets of Datasets

Usage

1
2
3
metaclipR.DatasetSubset(package = "transformeR", version = "1.3.2",
  graph = NULL, fun = NULL, arg.list = NULL, output = NULL,
  disable.command = FALSE)

Arguments

package

package

version

version

graph

A previously initialized metaclipR output list ($graph + $parentnodename). Default to NULL, which starts a new empty graph

fun

function name (default, and only value accepted is "subsetGrid")

arg.list

arg.list. See details

output

A climate4R grid, resulting from the application of subsetGrid.

disable.command

Better not to touch. For internal usage only (used to re-use most of the code in other functions, but skipping command tracking)

Details

This function takes as reference the semantics defined in the Data Source and Transformation ontology defined in the Metaclip Framework (http://metaclip.predictia.es/).

Value

A named list with the updated graph in element "graph" and the parent node name, sometimes needed for linking subsequent operations.

Argument list

A list of arguments passed to subsetGrid is required. The different arguments are explained in the the help menu of subsetGrid. The following list need to be specified. The default values are also indicated:

Author(s)

D. San Martín, J. Bedia

References

Visual schema of the data transformation ontology

Climate4R page at University of Cantabria

See Also

Other subsetting: metaclipR.loadeR

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
data(S4_tas_iberia)
require(transformeR)
require(igraph)
# An example subset from S4_tas_iberia
arg.list <- list(grid = S4_tas_iberia,
                 members = 1:3, # First three members (out of 15)
                 season = NULL,
                 years = 1991:1995, # Period 1991-1995
                 lonLim = c(-5,3), # longitudinal extent
                 latLim = c(37,43),
                 drop = FALSE) # latitudinal extent
# Dataset subset is applied using subsetGrid:
dataset.subset <- do.call("subsetGrid", args = arg.list)
# Just for illustration, visualization of the climatology:
plotClimatology(climatology(dataset.subset, by.member = FALSE),
                 backdrop.theme = "countries")
# Encoding provenance: 
dsgraph <- metaclipR.DatasetSubset(package = "transformeR",
                                   version = "1.1.1",
                                   fun = "subsetGrid",
                                   arg.list = arg.list,
                                   output = "dataset.subset")
# The Graph containing the metadata has been created.
# This is a bit congested, but note that it is not conceived to be visualized in R
plot(dsgraph$graph, vertex.size = 5, edge.arrow.size=0.1)

Predictia/metaclipR documentation built on May 14, 2019, 6:07 a.m.