I have been exploring the Rocket Launches project data in our newtFire eXist-db, to see about how to work with its xs:dateTime and xs:duration datatypes for use in charts and graphs. Before we can begin visualizing these data, we need to be able to survey it. A first stage was inspecting and cleaning up a few little errors in the duration datatype values, which are now ready for visualizing thanks to this team's dedicated work. The project has 124 small XML files and is helpful for modeling "date arithmetic."
To prepare the data for graphing on a screen, it needs to be converted from the complex format of the datatypes into a simpler decimal value. Here's an example file showing our input data. And here's what the datatype values look like:
xs:dateTime: 1981-11-12T10:09:59 representing "Nov. 12, 1981 at 10:09:59 a.m. EST"
I posted an XQuery script to survey the launch dates and the durations of each mission with simple text output to survey the 124 files in the Rocket Launches collection, and I wrote it using user-defined functions, that is functions you can write yourself that don't exist in the standard XPath collection. My XQuery is also posted in our newtfire eXist-db in /db/2020_ClassExamples/rocketDateDurationSurvey.xql
I have been exploring the Rocket Launches project data in our newtFire eXist-db, to see about how to work with its
xs:dateTime
andxs:duration
datatypes for use in charts and graphs. Before we can begin visualizing these data, we need to be able to survey it. A first stage was inspecting and cleaning up a few little errors in the duration datatype values, which are now ready for visualizing thanks to this team's dedicated work. The project has 124 small XML files and is helpful for modeling "date arithmetic."To prepare the data for graphing on a screen, it needs to be converted from the complex format of the datatypes into a simpler decimal value. Here's an example file showing our input data. And here's what the datatype values look like:
1981-11-12T10:09:59
representing "Nov. 12, 1981 at 10:09:59 a.m. EST"P2DT6H13M12S
representing "2 days, 6 hours, 13 minutes and 12 seconds"I posted an XQuery script to survey the launch dates and the durations of each mission with simple text output to survey the 124 files in the Rocket Launches collection, and I wrote it using user-defined functions, that is functions you can write yourself that don't exist in the standard XPath collection. My XQuery is also posted in our newtfire eXist-db in
/db/2020_ClassExamples/rocketDateDurationSurvey.xql