Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Table of Contents

Info
titleIncomplete

This page is being written. Please contact Mike Conlon if you have suggestions for this page.

Overview

VIVO can be used to mange the hierarchical structure, or organizational chart, of any organization.  We describe how VIVO represents organizational structure, and how to create data that can be loaded into VIVO to represent the structure of an organization.  The Sample Data has a sample university, with sample colleges and departments, illustrating the techniques described here.

...

To load data into VIVO, you will make triples out of your organizational data.  You can use tools such as Karma, SAS, python, the VIVO Pump, VIVO Harvester, XSLT, or your own scripts, or a text editor.

...

Code Block
languagexml
titleSample Triples
linenumberstrue
<http://vivo.mydomain.edu/individual/orgSampleUniversity> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#University> .
<http://vivo.mydomain.edu/individual/orgSampleUniversity> <http://www.w3.org/2000/01/rdf-schema#label> "Sample University"@en-US .
<http://vivo.mydomain.edu/individual/orgCollegeOfScience> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#College> .
<http://vivo.mydomain.edu/individual/orgCollegeOfScience> <http://www.w3.org/2000/01/rdf-schema#label> "College of Science"@en-US .
<http://vivo.mydomain.edu/individual/orgCollegeOfScience> <http://purl.obolibrary.org/obo/BFO_0000050>  <http://vivo.mydomain.edu/individual/orgSampleUniversity> .
<http://vivo.mydomain.edu/individual/orgPhysics> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#Department> .
<http://vivo.mydomain.edu/individual/orgPhysics> <http://www.w3.org/2000/01/rdf-schema#label> "Physics"@en-US .
<http://vivo.mydomain.edu/individual/orgPhysics> <http://purl.obolibrary.org/obo/BFO_0000050>  <http://vivo.mydomain.edu/individual/orgCollegeOfScience> .
<http://vivo.mydomain.edu/individual/orgChemistry> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#Department> .
<http://vivo.mydomain.edu/individual/orgChemistry> <http://www.w3.org/2000/01/rdf-schema#label> "Chemistry"@en-US .
<http://vivo.mydomain.edu/individual/orgChemistry> <http://purl.obolibrary.org/obo/BFO_0000050>  <http://vivo.mydomain.edu/individual/orgCollegeOfScience> .
<http://vivo.mydomain.edu/individual/orgOrganicChemistry> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#Division> .
<http://vivo.mydomain.edu/individual/orgOrganicChemistry> <http://www.w3.org/2000/01/rdf-schema#label> "Organic Chemistry"@en-US .
<http://vivo.mydomain.edu/individual/orgOrganicChemistry> <http://purl.obolibrary.org/obo/BFO_0000050>  <http://vivo.mydomain.edu/individual/orgChmistry>orgChemistry> .
<http://vivo.mydomain.edu/individual/orgCollegeOfTheArts> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#College> .
<http://vivo.mydomain.edu/individual/orgCollegeOfTheArts> <http://www.w3.org/2000/01/rdf-schema#label> "College of the Arts"@en-US .
<http://vivo.mydomain.edu/individual/orgCollegeOfTheArts> <http://purl.obolibrary.org/obo/BFO_0000050>  <http://vivo.mydomain.edu/individual/orgSampleUniversity> .
<http://vivo.mydomain.edu/individual/orgTheaterAndDance> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vivoweb.org/ontology/core#Department> .
<http://vivo.mydomain.edu/individual/orgTheaterAndDance> <http://www.w3.org/2000/01/rdf-schema#label> "Theater and Dance"@en-US .
<http://vivo.mydomain.edu/individual/orgTheaterAndDance> <http://purl.obolibrary.org/obo/BFO_0000050>  <http://vivo.mydomain.edu/individual/orgCollegeOfTheArts> .

...

  1. The triples are shown in N-triples format and should be stored in a file with the file type ".nt"  Elements of the triples are either URI (in brackets) or strings (in double quotes with a language tag). Each triple ends with a period.
  2. Each triple is of the form subject predicate object.  The subject is always a URI (in brackets) and is a URI you specify in your table of data.
  3. The predicates are from the ontologies VIVO uses to represent data.  They are also always URI (in brackets).  There are three kinds of assertions being made.  Each has its own predicate:
    1. The predicate to assert a type is  <http://www.w3.org/1999/02/22-rdf-syntax-ns#type>
    2. The predicate to assert a name, known as a label, is <http://www.w3.org/2000/01/rdf-schema#label>
    3. The predicate to assert that the organization is part of another organization is <http://purl.obolibrary.org/obo/BFO_0000050>

Managing the Triples in VIVO

Now that we have triples representing our organizations and their organization hierarchy, its easy to load them into VIVO and update them as necessary.  We will load the triples into a "named graph."  This is just a collection of triples with a name.  We will use a named graph to make it easy to update – we'll just empty the named graph and reload it.  That way we can be sure that the data in the file of triples is the data in the named graph.

Add the triples to VIVO

  1. Sign on VIVO as a system administrator.
  2. Navigate to Site Admin > Advanced Data Tools > Ingest Tools > Manage Jena Models
  3. At the top, click on the button "Create Model"
  4. Enter the name of your model.  Your name must be valid as part of a URI (no spaces).  Your might call your model "orgtest"
  5. Vitro creates a model with your name.  Find it in the list of models.  You should see:
    Image Added
  6. Click "load RDF data"
  7. Click Choose file and select your file of triples
  8. Click on the selector to indicate that your file is in "N-triples" format
  9. Click Load Data

You're done!  You have your organizations and your organizational hierarchy data in VIVO.  You can navigate to one of your organizations and see the hierarchical information:

Image Added

Updating your triples in VIVO

When you have organizational data to update – a new organization has been added, an organizational change has been made, an organization has a new name, you discovered an error in your data, or for any other reason, update the file with your triples and follow the steps below to replace your organizational data in VIVO with the organizational data in your file.

  1. Sign on VIVO as a system administrator.
  2. Navigate to Site Admin > Advanced Data Tools > Ingest Tools > Manage Jena Models
  3. Find your organization named graph it in the list of models.
  4. Carefully click "clear statements" for your organization named graph.  Be careful not to clear the statements of any other models.
  5. Click "Load RDF data"
  6. Click Choose file and select your file of triples
  7. Click on the selector to indicate that your file is in "N-triples" format
  8. Click Load Data

Your previous organization data has been replaced with your new organizational data.

Some Closing Observations

The basic technique for data management described here – creating triples, loading them into a named graph, and updating the graph when data changes – can be used to manage any of your VIVO data.  You can put people in one graph, publications in another, grants in another, datasets in another, and manage each by creating triples and updating graphs.  You may wish to create repeatable processes for each of the kinds of data you are managing.  These processes should be based on tools of your choice – Karma, XSLT, or scripts you write.

The Ontology Reference provides details regarding how VIVO represents entities.  Practice will lead to familiarity and the VIVO community is always happy to help with any questions you may have.