Project

General

Profile

1
<RESOURCE_PROFILE>
2
	<HEADER>
3
		<RESOURCE_IDENTIFIER value="8ae11a0a-4694-488b-b434-e654be62ca8f_VHJhbnNmb3JtYXRpb25SdWxlRFNSZXNvdXJjZXMvVHJhbnNmb3JtYXRpb25SdWxlRFNSZXNvdXJjZVR5cGU="/>
4
		<RESOURCE_TYPE value="TransformationRuleDSResourceType"/>
5
		<RESOURCE_KIND value="TransformationRuleDSResources"/>
6
		<RESOURCE_URI value=""/>
7
		<DATE_OF_CREATION value="2020-03-20T08:33:04+00:00"/>
8
	</HEADER>
9
	<BODY>
10
		<CONFIGURATION>
11
			<IMPORTED/>
12
			<SCRIPT>
13
				<TITLE>xslt_clinicaltrials.gov_datacite</TITLE>
14
				<CODE>
15
					<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:date="http://exslt.org/dates-and-times" xmlns:oaf="http://namespace.openaire.eu/oaf" xmlns:oai="http://www.openarchives.org/OAI/2.0/" xmlns:dri="http://www.driver-repository.eu/namespace/dri" xmlns:openTrials="eu.dnetlib.data.transform.xml.OpenTrialsXsltFunctions" xmlns:dr="http://www.driver-repository.eu/namespace/dr" exclude-result-prefixes="xsl" extension-element-prefixes="openTrials date" version="2.0">
16
						<xsl:output indent="yes"/>
17
						<xsl:param name="varOfficialName"/>
18
						<xsl:param name="varDataSourceId"/>
19
						<xsl:param name="quote">"</xsl:param>
20
						
21
						<xsl:template match="/">
22
							<xsl:call-template name="createRecord"/>
23
						</xsl:template>
24
						<xsl:template name="createRecord">
25
							<xsl:variable name="trialID" select="//id_info/nct_id"/>
26
							<oai:record>
27
								<oai:header>
28
									<xsl:copy-of copy-namespaces="no" select="//*[local-name() = 'header']/*"/>
29
									<dr:dateOfTransformation>
30
										<xsl:value-of select="date:date-time()"/>
31
									</dr:dateOfTransformation>
32
								</oai:header>
33
								<oai:metadata>
34
									<xsl:variable name="publicationYear"><xsl:value-of select="substring(//study_first_submitted, string-length(//study_first_submitted) - 4)"/></xsl:variable>
35
									<resource xmlns="http://datacite.org/schema/kernel-3" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://datacite.org/schema/kernel-3 http://schema.datacite.org/meta/kernel-3/metadata.xsd">
36
										<identifier identifierType="URL">
37
											<xsl:value-of select="//required_header/url"/>
38
										</identifier>
39
										<alternateIdentifiers>
40
											<alternateIdentifier alternateIdentifierType="NCT">
41
												<xsl:value-of select="$trialID"/>
42
											</alternateIdentifier>
43
										</alternateIdentifiers>
44
										<creators>
45
										<xsl:for-each select="//responsible_party[./responsible_party_type = 'Principal Investigator']/investigator_full_name | //responsible_party/name_title">
46
											<creator>
47
												<creatorName>
48
													<xsl:value-of select="."/>
49
												</creatorName>
50
											</creator>
51
										</xsl:for-each>
52
										</creators>
53
										<titles>
54
											<xsl:if test="(string-length(//official_title) &gt; 0)">
55
											<title>
56
												<xsl:value-of select="//official_title"/>
57
											</title>
58
											</xsl:if>
59
											<xsl:if test="(string-length(//brief_title) &gt; 0)">
60
											<title>
61
												<xsl:value-of select="//brief_title"/>
62
											</title>
63
											</xsl:if>
64
											<xsl:if test="(string-length(//acronym) &gt; 0)">
65
											<title>
66
												<xsl:value-of select="//acronym"/>
67
											</title>
68
											</xsl:if>
69
										</titles>
70
										<publisher>ClinicalTrials.org</publisher>
71
										<publicationYear><xsl:value-of select="$publicationYear"/></publicationYear>
72
										<dates>
73
											<date dateType="Submitted"><xsl:value-of select="//study_first_submitted"/></date>
74
											<date dateType="Updated"><xsl:value-of select="//last_update_submitted"/></date>
75
										</dates>
76
										<resourceType resourceTypeGeneral="clinicalTrial">0037</resourceType>
77
										<descriptions>
78
											<xsl:variable name="description" select="//detailed_description/textblock"/>
79
											<xsl:variable name="summary" select="//brief_summary/textblock"/>
80
											<xsl:if test="string-length($description) &gt; 0">
81
												<description descriptionType="Abstract">
82
													<xsl:value-of select="$description"/>
83
												</description>
84
											</xsl:if>
85
											<xsl:if test="string-length($summary) &gt; 0">
86
												<description descriptionType="Abstract">
87
													<xsl:value-of select="$summary"/>
88
												</description>
89
											</xsl:if>
90
										</descriptions>
91

    
92
										<subjects>
93
											<xsl:for-each select="//keyword">
94
												<subject><xsl:value-of select="."/></subject>
95
											</xsl:for-each>
96
										</subjects>
97
										<!-- TODO: map subjects inferred by Clinical trials? -->
98
									</resource>
99
									<xsl:for-each select="//location_countries/country">
100
										<oaf:country><xsl:value-of select="."/></oaf:country>
101
									</xsl:for-each>
102
									<oaf:accessrights>OPEN</oaf:accessrights>
103
									<dr:CobjCategory type="dataset">0037</dr:CobjCategory>
104
									<!-- only take the year -->
105
									<oaf:dateAccepted>
106
										<xsl:value-of select="$publicationYear"/>
107
									</oaf:dateAccepted>
108
									<oaf:hostedBy>
109
										<xsl:attribute name="name">
110
											<xsl:value-of select="$varOfficialName"/>
111
										</xsl:attribute>
112
										<xsl:attribute name="id">
113
											<xsl:value-of select="$varDataSourceId"/>
114
										</xsl:attribute>
115
									</oaf:hostedBy>
116
									<oaf:collectedFrom>
117
										<xsl:attribute name="name">
118
											<xsl:value-of select="$varOfficialName"/>
119
										</xsl:attribute>
120
										<xsl:attribute name="id">
121
											<xsl:value-of select="$varDataSourceId"/>
122
										</xsl:attribute>
123
									</oaf:collectedFrom>
124
									<oaf:about>
125
										<oaf:datainfo>
126
											<oaf:inferred>false</oaf:inferred>
127
											<oaf:deletedbyinference>false</oaf:deletedbyinference>
128
											<oaf:trust>0.9</oaf:trust>
129
											<oaf:inferenceprovenance/>
130
											<oaf:provenanceaction classid="sysimport:crosswalk:datasetarchive" classname="sysimport:crosswalk:datasetarchive" schemeid="dnet:provenanceActions" schemename="dnet:provenanceActions"/>
131
										</oaf:datainfo>
132
									</oaf:about>
133
								</oai:metadata>
134
								<xsl:copy-of select="//*[local-name() = 'about']"/>
135
							</oai:record>
136
						</xsl:template>
137
					</xsl:stylesheet>
138
				</CODE>
139
			</SCRIPT>
140
		</CONFIGURATION>
141
		<STATUS/>
142
		<SECURITY_PARAMETERS/>
143
	</BODY>
144
</RESOURCE_PROFILE>
(1-1/10)