Last data update: 2014.03.03

R: Class '"AnnotationHubMetadata"' and methods
AnnotationHubMetadata-classR Documentation

Class "AnnotationHubMetadata" and methods

Description

AnnotationHubMetadata is used to represent record(s) in the server data base.

Usage

AnnotationHubMetadata(AnnotationHubRoot, SourceUrl, SourceType,
                 SourceVersion, SourceLastModifiedDate, SourceMd5 =
                 NA_character_, SourceSize, DataProvider, Title,
                 Description, Species, TaxonomyId, Genome, Tags,
                 Recipe, RDataClass, RDataDateAdded, RDataPath,
                 Maintainer, ..., BiocVersion = biocVersion(),
                 Coordinate_1_based = TRUE, Notes = NA_character_,
                 DispatchClass, Location_Prefix =
                 "http://s3.amazonaws.com/annotationhub/")

jsonPath(x)
toJson(x)
constructAnnotationHubMetadataFromSourceFilePath(ahroot, originalFile)
constructMetadataFromJsonPath(ahroot, jsonpath)
constructSeqInfo(species, genome)

metadata(x, ...)
hubError(x)
inputFiles(object, ...)
outputFile(object)
ahmToJson(ahm)
deleteResources(id)
getImportPreparerClasses()
makeAnnotationHubResource(objName, makeAnnotationHubMetadataFunction,
                          ..., where)

Arguments

AnnotationHubRoot

character(1) Absolute path to directory structure containing resources to be added to AnnotationHub

SourceUrl

character() URL where resource(s) can be found

SourceType

character() which indicates what kind of resource was initially processed. The preference is to name the type of resource if it's a single file type and to name where the resources came from if it is a compound resource. So Typical answers would be like: 'BED','FASTA' or 'Inparanoid' etc.

SourceVersion

character(1) Version of original file

SourceLastModifiedDate

POSIXct() The date when the source was last modified. Leaving this blank should allow the values to be retrieved for you (if your sourceURL is valid).

SourceMd5

character() md5 hash of original file

SourceSize

numeric(1) Number of bytes in original file

DataProvider

character(1) Where did this resource come from?

Title

character(1) Title for this resource

Description

character(1) Description of the resource

Species

character(1) Species name

TaxonomyId

character(1) NCBI code

Genome

character(1) Name of genome build

Tags

character() Free-form tags

Recipe

character(1) Name of recipe function

RDataClass

character(1) Class of derived object (e.g. ‘GRanges’)

RDataDateAdded

POSIXct() Date added to AnnotationHub. Used to determine snapshots.

RDataPath

character(1) file path to serialized form

Maintainer

character(1) Maintainer name and email address, ‘A Maintainer a.maintainer@email.addr

BiocVersion

character(1) Under which resource was built

Coordinate_1_based

logical(1) Do coordinates start with 1 or 0?

DispatchClass

character(1) string used to indicate which code should be called by the client when the resource is downloaded. This is often the same as the RDataClass. But it is allowed to be a different value so that the client can do something different internally if required.

Location_Prefix

character(1) This was added for resources where the metadata only is stored and the resource itself comes from a third party web site. The location prefix says the base path where the resource is coming from, and the default value will be from our own site.

Notes

character() Notes about the resource.

ahm

An instance of class AnnotationHubMetadata.

x

An instance of class AnnotationHubMetadata.

jsonpath

character(1) full path to a JSON representation of AnnotationHubMetadata-class.

ahroot

A character(1) representing the value of AnnotationHubRoot to be added to the returned instance.

originalFile

Acharacter(1)

object

An AnnotationHubRecipe instance.

species

character(1) The organism, e.g., "Homo sapiens".

genome

character(1) The genome build, e.g., "hg19".

id

An id whose DB record is to be fully deleted (from gamay - not production)

objName

character(1) The name of the preparerClass object that you intend to have be used for dispatch. You can call it whatever you want as long as you don't use an existing preparerClass name

makeAnnotationHubMetadataFunction

function This is not a string, but just the name of the function that makes AHMs out of your resource of choice.

where

the environment in which to store the definition. Default value is sufficient.

...

additional arguments passed to methods

Value

AnnotationHubMetadata returns an instance of the class.

jsonPath returns a character(1)) representation of the full path to the location of the json file associated with this record.

toJson returns the JSON representation of the record.

fromJson retuns an instance of the class, as parsed from the JSON file.

Objects from the Class

Objects can be created by calls to the constructor, AnnotationHubMetadata().

Author(s)

Dan Tenenbaum and Marc Carlson

Examples

getClass("AnnotationHubMetadata")

Results


R version 3.3.1 (2016-06-21) -- "Bug in Your Hair"
Copyright (C) 2016 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu (64-bit)

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(AnnotationHubData)
Loading required package: S4Vectors
Loading required package: stats4
Loading required package: BiocGenerics
Loading required package: parallel

Attaching package: 'BiocGenerics'

The following objects are masked from 'package:parallel':

    clusterApply, clusterApplyLB, clusterCall, clusterEvalQ,
    clusterExport, clusterMap, parApply, parCapply, parLapply,
    parLapplyLB, parRapply, parSapply, parSapplyLB

The following objects are masked from 'package:stats':

    IQR, mad, xtabs

The following objects are masked from 'package:base':

    Filter, Find, Map, Position, Reduce, anyDuplicated, append,
    as.data.frame, cbind, colnames, do.call, duplicated, eval, evalq,
    get, grep, grepl, intersect, is.unsorted, lapply, lengths, mapply,
    match, mget, order, paste, pmax, pmax.int, pmin, pmin.int, rank,
    rbind, rownames, sapply, setdiff, sort, table, tapply, union,
    unique, unsplit


Attaching package: 'S4Vectors'

The following objects are masked from 'package:base':

    colMeans, colSums, expand.grid, rowMeans, rowSums

Loading required package: IRanges
Loading required package: GenomicRanges
Loading required package: GenomeInfoDb
Loading required package: AnnotationHub
Setting options('download.file.method.GEOquery'='auto')
Setting options('GEOquery.inmemory.gpl'=FALSE)
> png(filename="/home/ddbj/snapshot/RGM3/R_BC/result/AnnotationHubData/AnnotationHubMetadata-class.Rd_%03d_medium.png", width=480, height=480)
> ### Name: AnnotationHubMetadata-class
> ### Title: Class '"AnnotationHubMetadata"' and methods
> ### Aliases: class:HubMetadata HubMetadata-class HubMetadata
> ###   class:AnnotationHubMetadata AnnotationHubMetadata-class
> ###   AnnotationHubMetadata AnnotationHubMetadata metadata
> ###   metadata,HubMetadata-method metadata<-
> ###   metadata<-,HubMetadata,list-method inputFiles
> ###   inputFiles,HubMetadata-method outputFile
> ###   outputFile,HubMetadata-method recipeName
> ###   recipeName,HubMetadata-method hubError hubError,list-method
> ###   hubError,HubMetadata-method hubError<-
> ###   hubError<-,list,character-method
> ###   hubError<-,HubMetadata,character-method run
> ###   run,AnnotationHubMetadata-method jsonPath HubMetadataFromJson toJson
> ###   constructAnnotationHubMetadataFromSourceFilePath
> ###   constructMetadataFromJsonPath constructSeqInfo ahmToJson
> ###   deleteResources getImportPreparerClasses makeAnnotationHubResource
> ###   show show,HubMetadata-method
> ### Keywords: classes
> 
> ### ** Examples
> 
> getClass("AnnotationHubMetadata")
Class "AnnotationHubMetadata" [package "AnnotationHubData"]

Slots:
                                                                           
Name:       AnnotationHubRoot                HubRoot            BiocVersion
Class:              character              character        package_version
                                                                           
Name:      Coordinate_1_based           DataProvider             DerivedMd5
Class:                logical              character              character
                                                                           
Name:             Description                 Genome             Maintainer
Class:              character              character              character
                                                                           
Name:                   Notes             RDataClass         RDataDateAdded
Class:              character              character                POSIXct
                                                                           
Name:               RDataPath                 Recipe SourceLastModifiedDate
Class:              character              character                POSIXct
                                                                           
Name:               SourceMd5             SourceSize              SourceUrl
Class:              character                numeric              character
                                                                           
Name:           SourceVersion             SourceType                Species
Class:              character              character              character
                                                                           
Name:                    Tags             TaxonomyId                  Title
Class:              character                integer              character
                                                                           
Name:         Location_Prefix          DispatchClass          PreparerClass
Class:              character              character              character
                             
Name:                   Error
Class:              character

Extends: "HubMetadata"
> 
> 
> 
> 
> 
> dev.off()
null device 
          1 
>