Last data update: 2014.03.03

R: Metadata File Helpers
makeMetadataFromCsvR Documentation

Metadata File Helpers

Description

Read metadata file for an ExperimentHub resource into R

Usage

  makeExperimentHubMetadata(pathToPackage)
  readMetadataFromCsv(pathToPackage)

Arguments

pathToPackage

full path to package

Details

  • makeExperimentHubMetadata: Called by addResources. This function reads in the metadata.csv file of a contributed package and creates a ExperimentHubMetadata object to be inserted in the ExperimentHub database.

  • readMetadataFromCsv: Called by makeExperimentHubMetadata. This function reads in the metadata.csv file located in inst/extdata of the pathToPackage. It performs checks for required columns and data types and can be used by package authors to validate their metadata.csv.

    The rows of metadata.csv represent individual ExperimentHub resources (i.e., data objects) and the columns are the metadata fields. All fields should be a single character string of length 1. BiocVersion and Tags can have multiple comma-separated values within the string.

    Required fields in metadata.csv:

    • Title: character. Name of the resource.

    • Description: character. Brief description of the resource, similar to the 'Description' field in a package DESCRIPTION file.

    • BiocVersion: character. All Bioconductor versions the resource should be made available for; comma separated.

    • Genome: character. Genome.

    • SourceType: character. Format of original data, e.g., FASTA, BAM, BigWig, etc.

    • SourceUrl: character. Location of original data.

    • SourceVersion: character. Version of original data.

    • Species: character. Species.

    • TaxonomyId: character(1). Taxonomy ID.

    • Coordinate_1_based: logical. TRUE if data are 1-based.

    • DataProvider: character. Name of original data provider.

    • Maintainer: character. Maintainer name and email in the following format: Maintainer Name <username@address>.

    • RDataClass: character. R / Bioconductor class the data are stored in.

    • Tags: character. Free-form search terms to be used with query on an ExperimentHub object. The biocViews terms from the package DESCRIPTION are added to the Tag field when adding metadata to the database.

Value

readMetadataFromCsv() returns a data.frame and makeExperimetHubMetadata() returns a list of ExperimentHubMetadata objects.

See Also

  • addResources

  • ExperimentHubMetadata

Examples

## TODO

Results