Title: Creating EML using XMLSpy
1Creating EML using XMLSpy
- Second KNB Data Management Workshop
- 2-4 February 2005
- Mark Servilla
- LTER Network Office
- University of New Mexico, Albuquerque
2Agenda
- Objectives
- Introduction to XMLSpy
- Creating EML using XMLSpy
- Validating EML
3Objectives
- Why an XML editor?
- To create, edit, correct, or simply view XML
- Schema inspection
- Schema validation
- Which one
- Altova XMLSpy (www.altova.com)
- Stylus Studio (www.stylusstudio.com)
- Oxygen (www.oxygenxml.com)
- Hands on experience with XMLSpy
- Working with XML to create basic EML
- Validation of EML
4Schema View
5Document View
6Top level EML Schema structure
7Understanding the diagrams
ltemlgt lt/emlgt
root element
8Understanding the diagrams
ltemlgt ltadditionalMetadatagt
lt/additionalMetadatagt lt/emlgt
optional
9Understanding the diagrams
ltemlgt ltdatasetgt lt/datasetgt
ltadditionalMetadatagt lt/additionalMetadatagt
lt/emlgt
sequence
10Understanding the diagrams
ltemlgt ltdatasetgt lt/datasetgt
ltadditionalMetadatagt lt/additionalMetadatagt
lt/emlgt
choice
11Understanding the diagrams
ltemlgt ltdatasetgt lt/datasetgt
ltadditionalMetadatagt lt/additionalMetadatagt
ltadditionalMetadatagt
lt/additionalMetadatagt lt/emlgt
cardinality
12Understanding the diagrams
ltemlgt ltdatasetgt lt/datasetgt
ltadditionalMetadatagt lt/additionalMetadatagt
ltadditionalMetadatagt
lt/additionalMetadatagt lt/emlgt
complexType
13Begin A New EML Document
- Double-click on XMLSpy icon
- File New
- XML Document
- Schema Instance
- C\eml-2.0.1\eml.xsd
- EML root element
14Vestige of an EML Document
15Level 1- Identification
- Define packageId and system within opening ltemlgt
tag - packageIdknb-lter-sev.129.1 systemknb
- Define dataset title
- lttitlegt
- 1999 Central New Mexico Sevilleta LTER NPP
Quadrant Sampling Data - lt/titlegt
- Define dataset creator
- ltcreatorgt
- ltindividualNamegt
- ltgivenNamegtEstelt/givenNamegt
- ltsurNamegtMuldavinlt/surNamegt
- lt/individualNamegt
- lt/creatorgt
- Define dataset contact
- ltcontactgt
- ltindividualNamegt
- ltgivenNamegtKristinlt/givenNamegt
- ltsurNamegtVanderbiltlt/surNamegt
- lt/individualNamegt
16Level 1 Identification cont.
- Define dataset abstract
- ltabstractgt
- ltsectiongt
- ltparagtNet primary production (NPP) is
alt/paragt - lt/sectiongt
- lt/abstractgt
- Define dataset keywordSet
- ltkeywordSetgt
- ltkeyword keywordType"theme"gtANPPlt/keywordgt
- ltkeyword keywordType"theme"gtSevilletalt/keywordgt
- lt/keywordSetgt
17Level 2 - Discovery
- Define geographicCoverage and temporalCoverage
- ltcoveragegt
- ltgeographicCoveragegt
- ltgeographicDescriptiongt
- Sevilleta National Wildlife Refuge, Soccoro
County, New Mexico, USA - lt/geographicDescriptiongt
- ltboundingCoordinatesgt
- ltwestBoundingCoordinategt-107.113lt/westBoundi
ngCoordinategt - lteastBoundingCoordinategt-106.416lt/eastBoundi
ngCoordinategt - ltnorthBoundingCoordinategt34.463lt/northBound
ingCoordinategt - ltsouthBoundingCoordinategt34.158lt/southBound
ingCoordinategt - lt/boundingCoordinatesgt
- lt/geographicCoveragegt
- lttemporalCoveragegt
- ltsingleDateTimegt
- ltcalendarDategt1999-02-01lt/calendarDategt
- lt/singleDateTimegt
- ltsingleDateTimegt
- ltcalendarDategt1999-05-01lt/calendarDategt
18Level 3 - Evaluation
- Define intellectualRights
- ltintellectualRightsgt
- ltsectiongt
- ltparagt
- Any Sevilleta LTER data set and
accompanying metadata can be used - lt/paragt
- lt/sectiongt
- lt/intellectualRightsgt
- Define methods
- ltmethodsgt ltmethodStepgt
- ltdescriptiongt
- ltsectiongt
- ltparagt
- Locating the NPP Sampling Quadrats
- lt/paragt
- ltparagt
- Each core site contains five rodent
trapping webs. Each web - lt/paragt
- lt/sectiongt
19Level 3 Evaluation cont.
- Define dataTable and attributeList
- ltdataTablegt
- ltentityNamegtsev129.csvlt/entityNamegt
- ltentityDescriptiongt
- 1999 Sevilleta LTER NPP data
- lt/entityDescriptiongt
- ltattributeListgt
- ltattributegt
- ltattributeNamegtDATElt/attributeNamegt
- ltattributeDefinitiongt
- Date of data collection
- lt/attributeDefinitiongt
- ltmeasurementScalegt
- ltdatetimegt
- ltformatStringgtmm-dd-yyyylt/formatStringgt
- ltdateTimePrecisiongt0lt/dateTimePrecisi
ongt - ltdateTimeDomaingt
- ltboundsgt
- ltminimum exclusive"false"gt01-01-19
99lt/minimumgt
20Level 4 - Access
- Define physical
- ltphysicalgt
- ltobjectNamegtsev129.csvlt/objectNamegt
- ltsize unit"byte"gt376755lt/sizegt
- ltdataFormatgt
- lttextFormatgt
- ltnumHeaderLinesgt1lt/numHeaderLinesgt
- ltrecordDelimitergtx0Alt/recordDelimitergt
- ltattributeOrientationgtcolumnlt/attributeOrie
ntationgt - ltsimpleDelimitedgt
- ltfieldDelimitergt,lt/fieldDelimitergt
- lt/simpleDelimitedgt
- lt/textFormatgt
- lt/dataFormatgt
- ltdistributiongt
- ltonlinegt
- lturlgthttp//sevilleta.unm.edu/data1/NPP/sev12
9.csvlt/urlgt - lt/onlinegt
- lt/distributiongt
21Level 5 - Integration
- Define qualityControl
- ltqualityControlgt
- ltdescriptiongt
- ltsectiongt
- ltparagt
- Before data are concatenated into one
file - lt/paragt
- ltparagt
- Each field of data is filtered in Excel
to check for - lt/paragt
- lt/sectiongt
- lt/descriptiongt
- lt/qualityControlgt
22Validation
- Using XMLSpy to check for well-formed XML and
Schema validation
23Validation cont.
- Using the online validation service at
http//knb.ecoinformatics.org/emlparser/index.html
24Acknowledgements
This material is based upon work supported
by The National Science Foundation under Grant
Numbers 9980154, 9904777, 0131178, 9905838,
0129792, and 0225676. The National Center for
Ecological Analysis and Synthesis, a Center
funded by NSF (Grant Number 0072909), the
University of California, and the UC Santa
Barbara campus. The Andrew W. Mellon
Foundation. PBI Collaborators NCEAS, University
of New Mexico (Long Term Ecological Research
Network Office), San Diego Supercomputer Center,
University of Kansas (Center for Biodiversity
Research) Kepler contributors SEEK, Ptolemy II,
SDM/SciDAC, GEON