<?xml version="1.0" encoding="UTF-8"?>
<!-- edited with XMLSpy v2005 sp1 U (http://www.xmlspy.com) by Steve O'Hagan (The University of Manchester) -->
<!-- edited with XMLSPY v2004 rel. 4 U (http://www.xmlspy.com) by Irena Spasic (UMIST) -->
<!-- 
    SCHEMA: metabolomics.xsd
    AUTHOR: Irena Spasic
    LAST CHANGE: 28-09-2004
    DESCRIPTION: This document provides an XML schema for metabolomic footprinting.
-->
<xs:schema xmlns:ANL="http://www.analysis.com" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:ADM="http://www.admin.com" xmlns:SMP="http://www.samples.com" targetNamespace="http://www.analysis.com" elementFormDefault="unqualified" attributeFormDefault="unqualified">
	<xs:import namespace="http://www.admin.com" schemaLocation="admin.xsd"/>
	<xs:import namespace="http://www.samples.com" schemaLocation="samples.xsd"/>
	<xs:element name="Analysis">
		<xs:annotation>
			<xs:documentation>A sample is used as an input for an analytical experiment, performed by running an analytical instrument. This gives the analysis results.</xs:documentation>
		</xs:annotation>
		<xs:complexType>
			<xs:sequence>
				<xs:element name="file">
					<xs:annotation>
						<xs:documentation>Raw data file</xs:documentation>
					</xs:annotation>
					<xs:complexType>
						<xs:sequence>
							<xs:element name="url" type="xs:string">
								<xs:annotation>
									<xs:documentation>Uniform resource locator of the file.</xs:documentation>
								</xs:annotation>
							</xs:element>
							<xs:element name="type">
								<xs:annotation>
									<xs:documentation>Was the parent file a native acquisition file?  Or was it processed data?</xs:documentation>
								</xs:annotation>
								<xs:simpleType>
									<xs:restriction base="xs:string">
										<xs:enumeration value="raw data"/>
										<xs:enumeration value="processed data"/>
									</xs:restriction>
								</xs:simpleType>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
				</xs:element>
				<xs:choice>
					<xs:element ref="ANL:MassSpectrum"/>
					<xs:element name="gcmsPeakList">
						<xs:annotation>
							<xs:documentation>A GCMS peak list produced as an output of a GCMS run (corresponds to a minimal common output set for all GCMS instruments). There will be a gcmsPeakList element for each sample analysed on a GCMS instrument.</xs:documentation>
						</xs:annotation>
						<xs:complexType>
							<xs:sequence>
								<xs:element name="gcmsPeak" maxOccurs="unbounded">
									<xs:annotation>
										<xs:documentation>A GCMS peak as part of a GCMS peak list. There will be a gcmsPeak element for each peak in a GCMS peak list.</xs:documentation>
									</xs:annotation>
									<xs:complexType>
										<xs:sequence>
											<xs:element name="retention">
												<xs:complexType>
													<xs:sequence>
														<xs:element name="absolute" type="xs:float">
															<xs:annotation>
																<xs:documentation>The absolute retention time for the peak in seconds.</xs:documentation>
															</xs:annotation>
														</xs:element>
														<xs:element name="relative" type="xs:float" minOccurs="0">
															<xs:annotation>
																<xs:documentation>The relative retention time for the peak in seconds.</xs:documentation>
															</xs:annotation>
														</xs:element>
														<xs:element name="lower_bound" type="xs:float" minOccurs="0">
															<xs:annotation>
																<xs:documentation>The lower bound of the retention time window in which the peak falls.</xs:documentation>
															</xs:annotation>
														</xs:element>
														<xs:element name="upper_bound" type="xs:float" minOccurs="0">
															<xs:annotation>
																<xs:documentation>The upper bound of the retention time window in which the peak falls.</xs:documentation>
															</xs:annotation>
														</xs:element>
														<xs:element name="index" type="xs:float" minOccurs="0">
															<xs:annotation>
																<xs:documentation>A retention time index for the peak.</xs:documentation>
															</xs:annotation>
														</xs:element>
													</xs:sequence>
												</xs:complexType>
											</xs:element>
											<xs:element name="area">
												<xs:complexType>
													<xs:sequence>
														<xs:element name="absolute" type="xs:int">
															<xs:annotation>
																<xs:documentation>The absolute area of the peak in ???.</xs:documentation>
															</xs:annotation>
														</xs:element>
														<xs:element name="relative" type="xs:float" minOccurs="0">
															<xs:annotation>
																<xs:documentation>The relative area of the peak in ???.</xs:documentation>
															</xs:annotation>
														</xs:element>
													</xs:sequence>
												</xs:complexType>
											</xs:element>
											<xs:element ref="ANL:MassSpectrum"/>
										</xs:sequence>
									</xs:complexType>
								</xs:element>
								<xs:choice minOccurs="0">
									<xs:element name="lecoPeakInfo">
										<xs:complexType>
											<xs:sequence>
												<xs:element name="quantification" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The calibration/analyte name used for the quantification for this peak</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="name" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The name assigned to a peak. It can come from the library search, the quantification, auto naming from the software, or from the operator</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="sample_type" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The category the sample is in</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="unique_mass" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The mass value chosen by the instrument as the best peak based on purity calculations for the peak</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="concentration" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The concentration calculated for the corresponding analyte using the indicated calibration</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="match" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>A numerical description [0..999] of the match between the analyte and the referent mass spectrum. The higher the number, the better the match</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="quant_masses" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The m/z value used for quantification</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="quant_signal2noise" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The peak height of the quantified mass divided by the calculated noise</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="baseline_mod" type="xs:boolean" minOccurs="0">
													<xs:annotation>
														<xs:documentation>Indicator of manual modification of the analyte's baseline</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="non_saturated_apex" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>If the peak is saturated, this is the location of the closest point to the apex that is not saturated</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="signal2noise" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>Baseline corrected peak height of the unique mass divided by the noise</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="noise" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The variation of the signal as calculated from the analyte peaks</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="purity" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>A unitless value that helps to describe how much unique_mass coelutes with other compounds</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="hits" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The library hit(s) names found for the peak</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="synonyms" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>Synonym names for the compound corresponding to the best hit</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="similarity" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>A numerical description [0..999] (defined by the NIST search algorithm) of how well the library hit matches the peak using all masses. The higher the value the better the fit</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="reverse" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>A value [0..999] defined by the NIST search algorithm describing how well the library hit matched the peak using only the masses present in the NIST DB mass spectrum. The higher the value the better the fit</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="probability" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>An estimation of the likelihood that a matching compound has been found</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="CAS" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The CAS (Chemical Abstracts Service) registry number</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="library" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The name of the library used to identify the analyte</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="libraryID" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The NIST identification number of the matching compound for the selected hit</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="formula" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The chemical formula of the identified analyte based on the library search (hit)</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="weight" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The molecular weight of the matching compound</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="contributor" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The library contributor of the matching compound</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="hit_no" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The number of the selected hit</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="height" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The distance between horizontal lines passing through the maximum and baseline of the peak</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="ratio" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>ratio = As / Ais, where As = the response (are/height) of the analyte to be measured, Ais = the response of the internal standard</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="response_factor" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The measure of the mass spectral response of the analyte's wrt its concentration: RF = AS x Cis / (Ais x Cs), where As = the response (are/height) of the analyte being measured, Cis = the concentration of the internal standard, Ais = the response of the internal standard, Cs = the concentration of the analyte being measured</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="integration_begin_time" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The retention time at which peak integration started</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="integration_begin_scan" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The number of the scan at which peak integration started</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="integration_end_time" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The retention time at which peak integration ended</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="integration_end_scan" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The number of the scan at which peak integration ended</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="converted_concentration" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The concentration multiplied by the conversion factor from the calibration</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="concerns" minOccurs="0">
													<xs:annotation>
														<xs:documentation>Definition of what makes the peak a problem (II = isomer interference, SM = saturated mass, QM = low quantification mass match, LM = low library much) </xs:documentation>
													</xs:annotation>
													<xs:simpleType>
														<xs:restriction base="xs:string">
															<xs:enumeration value="II"/>
															<xs:enumeration value="SM"/>
															<xs:enumeration value="QM"/>
															<xs:enumeration value="LM"/>
															<xs:enumeration value="None"/>
														</xs:restriction>
													</xs:simpleType>
												</xs:element>
												<xs:element name="group" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The name given for that quantification of the peak.</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="analyteID" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The user-given name for the compound</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="isotope_masses" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>Isotope masses entered in the calibration table</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="isotope_ratio" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The ratio between the expected isotope ratio and the calculated isotope ratio</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="isotope_ratio_result" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>Displays if the isotope ratio passed or failed according to the parameters set in isotope ratio tolerance in the calibration table</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="calibration" type="xs:string" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The calibration name used for the quantification of the peak</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="half_height_width" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The number of spectrum wide that the peak is at approximately half the height of the peak</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="sample_concentration" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The amount of analyte in the sample before any dilution</xs:documentation>
													</xs:annotation>
												</xs:element>
											</xs:sequence>
										</xs:complexType>
									</xs:element>
									<xs:element name="agilentPeakInfo">
										<xs:annotation>
											<xs:documentation>Additional information supplied for a GCMS peak produced by an Agilent instrument.</xs:documentation>
										</xs:annotation>
										<xs:complexType>
											<xs:sequence>
												<xs:element name="unique_mass" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The mass-to-charge value chosen by the instrument as the best peak based on purity calculations for the peak.</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="integration_start_scan" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The number of the scan at which peak integration started.</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="apex_scan" type="xs:int" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The scan number at the apex of the peak.</xs:documentation>
													</xs:annotation>
												</xs:element>
												<xs:element name="derivatives" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The derivatives of the peak compound.</xs:documentation>
													</xs:annotation>
													<xs:complexType>
														<xs:sequence>
															<xs:element name="derivative" type="xs:string" maxOccurs="unbounded"/>
														</xs:sequence>
													</xs:complexType>
												</xs:element>
												<xs:element name="relative_intensity" type="xs:float" minOccurs="0">
													<xs:annotation>
														<xs:documentation>The relative intensity of the unique ion excluding system peaks in the calculation.</xs:documentation>
													</xs:annotation>
												</xs:element>
											</xs:sequence>
										</xs:complexType>
									</xs:element>
								</xs:choice>
								<xs:element ref="ADM:comment" minOccurs="0"/>
							</xs:sequence>
						</xs:complexType>
					</xs:element>
					<xs:element name="ftirSpectrum">
						<xs:annotation>
							<xs:documentation>An FT-IR spectrum produced as an output of an FT-IR run (corresponds to a minimal common output set for all FT-IR instruments). There will be an ftirSpectrum element for each spectrum in a sample analysed on an FT-IR instrument.</xs:documentation>
						</xs:annotation>
						<xs:complexType>
							<xs:sequence>
								<xs:element name="ftirPeak" maxOccurs="unbounded">
									<xs:annotation>
										<xs:documentation>An FT-IR peak as part of a FT-IR spectrum. There will be an ftirPoint element for each peak in an FTIR spectrum.</xs:documentation>
									</xs:annotation>
									<xs:complexType>
										<xs:sequence>
											<xs:element name="wave_number"/>
											<xs:element name="absorbance"/>
										</xs:sequence>
									</xs:complexType>
								</xs:element>
								<xs:element ref="ADM:comment" minOccurs="0"/>
							</xs:sequence>
						</xs:complexType>
					</xs:element>
					<xs:element name="RamanSpectrum">
						<xs:annotation>
							<xs:documentation>A Raman spectrum produced as an output of a Raman run (corresponds to a minimal common output set for all Raman instruments). There will be a RamanSpectrum element for each spectrum in a sample analysed on a Raman instrument.</xs:documentation>
						</xs:annotation>
						<xs:complexType>
							<xs:sequence>
								<xs:element name="RamanPeak" maxOccurs="unbounded">
									<xs:annotation>
										<xs:documentation>An Raman peak as part of a Raman spectrum. There will be a ramanPeak element for each peak in a Raman spectrum.</xs:documentation>
									</xs:annotation>
									<xs:complexType>
										<xs:sequence>
											<xs:element name="raman_shift"/>
											<xs:element name="intensity"/>
										</xs:sequence>
									</xs:complexType>
								</xs:element>
								<xs:element ref="ADM:comment" minOccurs="0"/>
							</xs:sequence>
						</xs:complexType>
					</xs:element>
				</xs:choice>
				<xs:element name="MetabolitesIdentified" minOccurs="0">
					<xs:complexType>
						<xs:sequence>
							<xs:element name="metabolite" maxOccurs="unbounded">
								<xs:complexType>
									<xs:simpleContent>
										<xs:extension base="xs:string">
											<xs:attribute name="confidence" type="xs:float" use="optional"/>
											<xs:attribute name="concentration" type="xs:float" use="optional"/>
										</xs:extension>
									</xs:simpleContent>
								</xs:complexType>
							</xs:element>
						</xs:sequence>
					</xs:complexType>
				</xs:element>
				<xs:element ref="ADM:comment" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="ID" type="xs:ID">
				<xs:annotation>
					<xs:documentation>An ID for analytical results and a reference to an analytical experiment used to perform produce them</xs:documentation>
				</xs:annotation>
			</xs:attribute>
			<xs:attribute name="sample" type="xs:IDREF">
				<xs:annotation>
					<xs:documentation>A reference to the sample analysed</xs:documentation>
				</xs:annotation>
			</xs:attribute>
		</xs:complexType>
		<xs:key name="AnalysisID">
			<xs:selector xpath="."/>
			<xs:field xpath="@ID"/>
		</xs:key>
		<xs:keyref name="AnalyticalExperiment" refer="ADM:ExperimentID">
			<xs:selector xpath="."/>
			<xs:field xpath="@ID"/>
		</xs:keyref>
		<xs:keyref name="Sample" refer="SMP:SampleID">
			<xs:selector xpath="."/>
			<xs:field xpath="@sample"/>
		</xs:keyref>
	</xs:element>
	<xs:element name="MassSpectrum">
		<xs:annotation>
			<xs:documentation>A mass spectrum produced by a MS instrument (e.g. DIMS, GCMS).</xs:documentation>
		</xs:annotation>
		<xs:complexType>
			<xs:sequence>
				<xs:element ref="ANL:msPeak" maxOccurs="unbounded"/>
				<xs:element ref="ADM:comment" minOccurs="0"/>
			</xs:sequence>
			<xs:attribute name="ID" type="xs:ID" use="required"/>
			<xs:attribute name="ms_level" type="xs:short" use="optional" default="1">
				<xs:annotation>
					<xs:documentation>The level of the mass spectrum for tandem MS.</xs:documentation>
				</xs:annotation>
			</xs:attribute>
		</xs:complexType>
	</xs:element>
	<xs:element name="msPeak">
		<xs:annotation>
			<xs:documentation>A mass peak produced as part of a mass spectrum.</xs:documentation>
		</xs:annotation>
		<xs:complexType>
			<xs:sequence>
				<xs:element name="mz_value" type="xs:int">
					<xs:annotation>
						<xs:documentation>A mass-to-charge value.</xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element name="absolute_intensity" type="xs:int">
					<xs:annotation>
						<xs:documentation>The absolute intensity registered for the given mass-to-charge value.</xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element name="relative_intensity_tic" type="xs:double" minOccurs="0">
					<xs:annotation>
						<xs:documentation>The intensity relative to the total ion current (TIC).</xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element name="relative_intensity_height" type="xs:double" minOccurs="0">
					<xs:annotation>
						<xs:documentation>The intensity relative to the maximal peak height.</xs:documentation>
					</xs:annotation>
				</xs:element>
				<xs:element ref="ANL:MassSpectrum" minOccurs="0">
					<xs:annotation>
						<xs:documentation>Tandem mass spectrum.</xs:documentation>
					</xs:annotation>
				</xs:element>
			</xs:sequence>
		</xs:complexType>
	</xs:element>
</xs:schema>
