-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #40 from lgatto/ols4
Merge branch ols4
- Loading branch information
Showing
41 changed files
with
2,870 additions
and
2,662 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
Package: rols | ||
Type: Package | ||
Title: An R interface to the Ontology Lookup Service | ||
Version: 2.31.0 | ||
Version: 2.99.0 | ||
Authors@R: c(person(given = "Laurent", family = "Gatto", | ||
email = "[email protected]", | ||
role = c("aut","cre")), | ||
|
@@ -13,8 +13,8 @@ Description: The rols package is an interface to the Ontology Lookup | |
Service (OLS) to access and query hundred of ontolgies | ||
directly from R. | ||
Depends: methods | ||
Imports: httr, progress, jsonlite, utils, Biobase, | ||
BiocGenerics (>= 0.23.1) | ||
Imports: httr2, jsonlite, | ||
utils, Biobase, BiocGenerics (>= 0.23.1) | ||
Suggests: GO.db, knitr (>= 1.1.0), BiocStyle (>= 2.5.19), | ||
testthat, lubridate, DT, rmarkdown, | ||
biocViews: ImmunoOncology, Software, Annotation, MassSpectrometry, GO | ||
|
@@ -23,7 +23,8 @@ License: GPL-2 | |
Encoding: UTF-8 | ||
URL: http://lgatto.github.io/rols/ | ||
BugReports: https://github.com/lgatto/rols/issues | ||
Collate: AllClasses.R AllGenerics.R utils.R cvparam.R | ||
methods-OlsSearch.R methods-Ontologies.R methods-Terms.R | ||
methods-Properties.R zzz.R | ||
RoxygenNote: 6.1.0 | ||
Collate: AllClasses.R AllGenerics.R utils.R | ||
Ontologies.R Terms.R | ||
cvparam.R OlsSearch.R | ||
Properties.R zzz.R | ||
RoxygenNote: 7.3.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,61 +1,61 @@ | ||
import(methods) | ||
import(utils) | ||
import(httr) | ||
import(jsonlite) | ||
import(progress) | ||
importFrom(Biobase, validMsg) | ||
importFrom(BiocGenerics, Ontology) | ||
importClassesFrom(Biobase, Versioned) | ||
|
||
exportClasses(CVParam, | ||
Term, Terms, | ||
Ontology, Ontologies, | ||
OlsSearch, | ||
Property, Properties) | ||
|
||
S3method(as.data.frame, OlsSearch) | ||
# Generated by roxygen2: do not edit by hand | ||
|
||
exportMethods(show, | ||
"[", "[[", lapply, | ||
coerce, | ||
length, | ||
unique, | ||
## Ontology/ies | ||
Ontology, Ontologies, | ||
olsRoot, | ||
olsPrefix, | ||
olsDesc, | ||
olsTitle, | ||
olsStatus, | ||
olsNamespace, | ||
## Term/s | ||
all.equal, | ||
termLabel, | ||
termPrefix, | ||
termNamespace, | ||
termOntology, | ||
termDesc, | ||
term, terms, | ||
termId, | ||
## Property/ies | ||
properties) | ||
|
||
|
||
export(charIsCVParam, CVParam, | ||
## Ontology/ies | ||
olsVersion, | ||
olsLoaded, | ||
olsUpdated, | ||
## Term/s | ||
isObsolete, | ||
isRoot, | ||
termSynonym, | ||
children, parents, | ||
ancestors, descendants, | ||
derivesFrom, partOf, | ||
as.Term.data.frame, | ||
as.Terms.data.frame, | ||
## Search/select | ||
OlsSearch, | ||
olsSearch, | ||
olsRows, "olsRows<-", allRows) | ||
S3method(as.character,CVParam) | ||
S3method(as.data.frame,OlsSearch) | ||
S3method(as.data.frame,Ontologies) | ||
export("olsRows<-") | ||
export(CVParam) | ||
export(OlsSearch) | ||
export(allRows) | ||
export(ancestors) | ||
export(as.Term.data.frame) | ||
export(as.Terms.data.frame) | ||
export(charIsCVParam) | ||
export(children) | ||
export(cvCharToCVPar) | ||
export(descendants) | ||
export(olsRows) | ||
export(olsSearch) | ||
export(parents) | ||
exportMethods("[") | ||
exportMethods("[[") | ||
exportMethods(Ontologies) | ||
exportMethods(Ontology) | ||
exportMethods(Properties) | ||
exportMethods(Term) | ||
exportMethods(Terms) | ||
exportMethods(isObsolete) | ||
exportMethods(isRoot) | ||
exportMethods(lapply) | ||
exportMethods(length) | ||
exportMethods(olsConfig) | ||
exportMethods(olsDesc) | ||
exportMethods(olsLinks) | ||
exportMethods(olsLoaded) | ||
exportMethods(olsNamespace) | ||
exportMethods(olsPrefix) | ||
exportMethods(olsStatus) | ||
exportMethods(olsTitle) | ||
exportMethods(olsUpdated) | ||
exportMethods(olsVersion) | ||
exportMethods(ontologyUrl) | ||
exportMethods(rep) | ||
exportMethods(show) | ||
exportMethods(termDesc) | ||
exportMethods(termId) | ||
exportMethods(termLabel) | ||
exportMethods(termLinks) | ||
exportMethods(termNamespace) | ||
exportMethods(termOntology) | ||
exportMethods(termPrefix) | ||
exportMethods(termSynonym) | ||
exportMethods(unique) | ||
import(httr2) | ||
import(methods) | ||
importFrom(Biobase,validMsg) | ||
importFrom(jsonlite,fromJSON) | ||
importFrom(utils,URLencode) | ||
importFrom(utils,head) | ||
importFrom(utils,packageVersion) | ||
importFrom(utils,tail) | ||
importMethodsFrom(BiocGenerics,Ontology) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,91 +1,3 @@ | ||
setClassUnion("NullOrChar", c("NULL", "character")) | ||
setClassUnion("NullOrList", c("NULL", "list")) | ||
|
||
## a param is [CV label, accession, name|synonym, value] | ||
.CVParam <- setClass("CVParam", | ||
representation = representation( | ||
label = "character", | ||
accession = "character", | ||
name = "character", | ||
value = "character", | ||
user = "logical"), | ||
contains = "Versioned", | ||
prototype = prototype( | ||
user = FALSE, | ||
new("Versioned", versions=c(CVParam="0.2.0"))), | ||
validity = function(object) { | ||
msg <- validMsg(NULL, NULL) | ||
if (object@user) { | ||
if (!all(c(object@label, object@accession) == "")) | ||
msg <- "Label and accession must be empty in UserParams." | ||
} else { | ||
x <- c(object@label, object@accession, | ||
object@name, object@value) == "" | ||
if (!all(x)) { | ||
._term <- term(object@label, object@accession) | ||
._label <- termLabel(._term) | ||
._synonyms <- termSynonym(._term) | ||
if (!(object@name %in% c(._label, ._synonyms))) | ||
msg <- paste0("CVParam accession and name/synomyms do not match. Got [", | ||
paste(c(._label, ._synonyms), collapse = ", "), | ||
"], expected '", object@name, "'.") | ||
} | ||
} | ||
if (is.null(msg)) TRUE else msg | ||
}) | ||
|
||
|
||
.Ontology <- setClass("Ontology", | ||
slots = c(loaded = "NullOrChar", | ||
updated = "NullOrChar", | ||
status = "NullOrChar", | ||
message = "NullOrChar", | ||
version = "NullOrChar", | ||
numberOfTerms = "integer", | ||
numberOfProperties = "integer", | ||
numberOfIndividuals = "integer", | ||
config = "list" | ||
)) | ||
|
||
.Ontologies <- setClass("Ontologies", slots = c(x = "list")) | ||
|
||
.Term <- setClass("Term", | ||
slots = c(iri = "character", | ||
label = "character", | ||
description = "NullOrList", | ||
annotation = "list", | ||
synonym = "NullOrList", | ||
ontology_name = "character", | ||
ontology_prefix = "character", | ||
ontology_iri = "character", | ||
is_obsolete = "logical", | ||
is_defining_ontology = "logical", | ||
has_children = "logical", | ||
is_root = "logical", | ||
short_form = "character", | ||
obo_id = "NullOrChar", | ||
links = "list")) | ||
|
||
Terms <- setClass("Terms", slots = c(x = "list")) | ||
|
||
.OlsSearch <- setClass("OlsSearch", | ||
slots = c(q = "character", | ||
ontology = "character", | ||
type = "character", | ||
slim = "character", | ||
fieldList = "character", | ||
queryFields = "character", | ||
exact = "logical", | ||
groupField = "logical", | ||
obsoletes = "logical", | ||
local = "character", | ||
childrenOf = "character", | ||
rows = "integer", | ||
start = "integer", | ||
url = "character", | ||
numFound = "integer", | ||
response = "data.frame")) | ||
|
||
.Property <- setClass("Property", | ||
contains = "Term") | ||
Properties <- setClass("Properties", contains = "Terms") | ||
setClassUnion("NullOrLogical", c("NULL", "logical")) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.