... | ... |
@@ -1,9 +1,9 @@ |
1 | 1 |
% Generated by roxygen2: do not edit by hand |
2 | 2 |
% Please edit documentation in R/gmql_merge.R |
3 |
-\docType{methods} |
|
4 | 3 |
\name{aggregate} |
5 | 4 |
\alias{aggregate} |
6 | 5 |
\alias{aggregate,GMQLDataset-method} |
6 |
+\alias{aggregate-method} |
|
7 | 7 |
\title{Method aggregate} |
8 | 8 |
\usage{ |
9 | 9 |
\S4method{aggregate}{GMQLDataset}(x, groupBy = conds()) |
... | ... |
@@ -36,7 +36,7 @@ not present in the grouping metadata parameter are disregarded. |
36 | 36 |
## and creation of results on disk. Then, with system.file() it defines |
37 | 37 |
## the path to the folder "DATASET" in the subdirectory "example" |
38 | 38 |
## of the package "RGMQL" and opens such file as a GMQL dataset named "exp" |
39 |
-## using customParser |
|
39 |
+## using CustomParser |
|
40 | 40 |
|
41 | 41 |
init_gmql() |
42 | 42 |
test_path <- system.file("example", "DATASET", package = "RGMQL") |
... | ... |
@@ -24,7 +24,7 @@ Wrapper to GMQL MERGE operator |
24 | 24 |
It builds a dataset consisting of a single sample having as |
25 | 25 |
many regions as the number of regions of all the input dataset samples |
26 | 26 |
and as many metadata as the union of the 'attribute-value' tuples of the |
27 |
-input samples. If \emph{groupBy} is specified: the samples are then |
|
27 |
+input samples. If \emph{groupBy} is specified, the samples are then |
|
28 | 28 |
partitioned in groups, each with a distinct value of the grouping metadata |
29 | 29 |
attributes. The operation is separately applied to each group, yielding |
30 | 30 |
one sample in the result for each group. Samples whose metadata are |
... | ... |
@@ -39,16 +39,15 @@ not present in the grouping metadata parameter are disregarded. |
39 | 39 |
## using customParser |
40 | 40 |
|
41 | 41 |
init_gmql() |
42 |
-test_path <- system.file("example","DATASET",package = "RGMQL") |
|
43 |
-exp = read_GMQL(test_path) |
|
42 |
+test_path <- system.file("example", "DATASET", package = "RGMQL") |
|
43 |
+exp = read_gmql(test_path) |
|
44 | 44 |
|
45 | 45 |
## This statement creates a dataset called merged which contains one |
46 | 46 |
## sample for each antibody_target and cell value found within the metadata |
47 | 47 |
## of the exp dataset sample; each created sample contains all regions |
48 | 48 |
## from all 'exp' samples with a specific value for their |
49 |
-## antibody_target and cell metadata |
|
50 |
-## attributes. |
|
49 |
+## antibody_target and cell metadata attributes. |
|
51 | 50 |
|
52 |
-merged = aggregate(exp, conds(c("antibody_target","cell"))) |
|
51 |
+merged = aggregate(exp, conds(c("antibody_target", "cell"))) |
|
53 | 52 |
|
54 | 53 |
} |
... | ... |
@@ -6,7 +6,7 @@ |
6 | 6 |
\alias{aggregate,GMQLDataset-method} |
7 | 7 |
\title{Method aggregate} |
8 | 8 |
\usage{ |
9 |
-\S4method{aggregate}{GMQLDataset}(x, groupBy = NULL) |
|
9 |
+\S4method{aggregate}{GMQLDataset}(x, groupBy = conds()) |
|
10 | 10 |
} |
11 | 11 |
\arguments{ |
12 | 12 |
\item{x}{GMQLDataset class object} |
... | ... |
@@ -40,7 +40,7 @@ not present in the grouping metadata parameter are disregarded. |
40 | 40 |
|
41 | 41 |
init_gmql() |
42 | 42 |
test_path <- system.file("example","DATASET",package = "RGMQL") |
43 |
-exp = read_dataset(test_path) |
|
43 |
+exp = read_GMQL(test_path) |
|
44 | 44 |
|
45 | 45 |
## This statement creates a dataset called merged which contains one |
46 | 46 |
## sample for each antibody_target and cell value found within the metadata |
... | ... |
@@ -49,6 +49,6 @@ exp = read_dataset(test_path) |
49 | 49 |
## antibody_target and cell metadata |
50 | 50 |
## attributes. |
51 | 51 |
|
52 |
-merged = aggregate(exp, condition_evaluation(c("antibody_target","cell"))) |
|
52 |
+merged = aggregate(exp, conds(c("antibody_target","cell"))) |
|
53 | 53 |
|
54 | 54 |
} |
... | ... |
@@ -11,16 +11,8 @@ |
11 | 11 |
\arguments{ |
12 | 12 |
\item{x}{GMQLDataset class object} |
13 | 13 |
|
14 |
-\item{groupBy}{list of evalation functions to define evaluation on metadata: |
|
15 |
-\itemize{ |
|
16 |
-\item{\code{\link{FN}}(value): Fullname evaluation, two attributes match |
|
17 |
-if they both end with \emph{value} and, if they have further prefixes, |
|
18 |
-the two prefix sequences are identical} |
|
19 |
-\item{\code{\link{EX}}(value): Exact evaluation, only attributes exactly |
|
20 |
-as \emph{value} match; no further prefixes are allowed. } |
|
21 |
-\item{\code{\link{DF}}(value): Default evaluation, the two attributes match |
|
22 |
-if both end with \emph{value}.} |
|
23 |
-}} |
|
14 |
+\item{groupBy}{\code{\link{condition_evaluation}} function to support |
|
15 |
+methods with groupBy or JoinBy input paramter} |
|
24 | 16 |
} |
25 | 17 |
\value{ |
26 | 18 |
GMQLDataset object. It contains the value to use as input |
... | ... |
@@ -57,6 +49,6 @@ exp = read_dataset(test_path) |
57 | 49 |
## antibody_target and cell metadata |
58 | 50 |
## attributes. |
59 | 51 |
|
60 |
-merged = aggregate(exp, list(DF("antibody_target","cell"))) |
|
52 |
+merged = aggregate(exp, condition_evaluation(c("antibody_target","cell"))) |
|
61 | 53 |
|
62 | 54 |
} |
1 | 1 |
new file mode 100644 |
... | ... |
@@ -0,0 +1,62 @@ |
1 |
+% Generated by roxygen2: do not edit by hand |
|
2 |
+% Please edit documentation in R/gmql_merge.R |
|
3 |
+\docType{methods} |
|
4 |
+\name{aggregate} |
|
5 |
+\alias{aggregate} |
|
6 |
+\alias{aggregate,GMQLDataset-method} |
|
7 |
+\title{Method aggregate} |
|
8 |
+\usage{ |
|
9 |
+\S4method{aggregate}{GMQLDataset}(x, groupBy = NULL) |
|
10 |
+} |
|
11 |
+\arguments{ |
|
12 |
+\item{x}{GMQLDataset class object} |
|
13 |
+ |
|
14 |
+\item{groupBy}{list of evalation functions to define evaluation on metadata: |
|
15 |
+\itemize{ |
|
16 |
+\item{\code{\link{FN}}(value): Fullname evaluation, two attributes match |
|
17 |
+if they both end with \emph{value} and, if they have further prefixes, |
|
18 |
+the two prefix sequences are identical} |
|
19 |
+\item{\code{\link{EX}}(value): Exact evaluation, only attributes exactly |
|
20 |
+as \emph{value} match; no further prefixes are allowed. } |
|
21 |
+\item{\code{\link{DF}}(value): Default evaluation, the two attributes match |
|
22 |
+if both end with \emph{value}.} |
|
23 |
+}} |
|
24 |
+} |
|
25 |
+\value{ |
|
26 |
+GMQLDataset object. It contains the value to use as input |
|
27 |
+for the subsequent GMQLDataset method |
|
28 |
+} |
|
29 |
+\description{ |
|
30 |
+Wrapper to GMQL MERGE operator |
|
31 |
+ |
|
32 |
+It builds a dataset consisting of a single sample having as |
|
33 |
+many regions as the number of regions of all the input dataset samples |
|
34 |
+and as many metadata as the union of the 'attribute-value' tuples of the |
|
35 |
+input samples. If \emph{groupBy} is specified: the samples are then |
|
36 |
+partitioned in groups, each with a distinct value of the grouping metadata |
|
37 |
+attributes. The operation is separately applied to each group, yielding |
|
38 |
+one sample in the result for each group. Samples whose metadata are |
|
39 |
+not present in the grouping metadata parameter are disregarded. |
|
40 |
+} |
|
41 |
+\examples{ |
|
42 |
+ |
|
43 |
+## This statement initializes and runs the GMQL server for local execution |
|
44 |
+## and creation of results on disk. Then, with system.file() it defines |
|
45 |
+## the path to the folder "DATASET" in the subdirectory "example" |
|
46 |
+## of the package "RGMQL" and opens such file as a GMQL dataset named "exp" |
|
47 |
+## using customParser |
|
48 |
+ |
|
49 |
+init_gmql() |
|
50 |
+test_path <- system.file("example","DATASET",package = "RGMQL") |
|
51 |
+exp = read_dataset(test_path) |
|
52 |
+ |
|
53 |
+## This statement creates a dataset called merged which contains one |
|
54 |
+## sample for each antibody_target and cell value found within the metadata |
|
55 |
+## of the exp dataset sample; each created sample contains all regions |
|
56 |
+## from all 'exp' samples with a specific value for their |
|
57 |
+## antibody_target and cell metadata |
|
58 |
+## attributes. |
|
59 |
+ |
|
60 |
+merged = aggregate(exp, list(DF("antibody_target","cell"))) |
|
61 |
+ |
|
62 |
+} |