Skip to content

Commit

Permalink
Added new data set for clinical-timelines testing
Browse files Browse the repository at this point in the history
  • Loading branch information
jwildfire committed Jan 9, 2018
1 parent 6ed4b01 commit e8eacd1
Show file tree
Hide file tree
Showing 8 changed files with 1,904 additions and 1,545 deletions.
1,068 changes: 1,068 additions & 0 deletions data/testData/ADTIMELINES_missingAdded.csv

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions scripts/buildExample/makeExampleIndex.js
Original file line number Diff line number Diff line change
Expand Up @@ -96,9 +96,9 @@ exports.makeExampleIndex = function(ex) {
.append("span")
.html(
d =>
d == "data" || d == "results" || d == "code"
(d == "data" || d == "results" || d == "code"
? "<a href='" + ex[d] + "'>" + ex[d] + "</a>"
: ex[d]
: ex[d])
);

// parse any extra readme content
Expand Down Expand Up @@ -127,8 +127,9 @@ exports.makeExampleIndex = function(ex) {
ex.paths.example +
'" width=960></div>';
var exampleExt = ex.paths.example.split(".").pop();
var exampleContent_html =
exampleExt == "html" ? webExampleContent : staticExampleContent;
var exampleContent_html = exampleExt == "html"
? webExampleContent
: staticExampleContent;

window.d3
.select("body")
Expand Down
11 changes: 5 additions & 6 deletions scripts/parseExamples.js
Original file line number Diff line number Diff line change
Expand Up @@ -67,10 +67,9 @@ examples.forEach(function(ex) {
var attrMatch = lines.filter(function(line) {
return c.regex.test(line);
});
ex[c.value] =
attrMatch.length == 1
? attrMatch[0].match(/([^(**)]+$)/)[0].trim()
: null;
ex[c.value] = attrMatch.length == 1
? attrMatch[0].match(/([^(**)]+$)/)[0].trim()
: null;
});

//parse langauges and libraries to arrays
Expand Down Expand Up @@ -99,8 +98,8 @@ examples.forEach(function(ex) {
ex.paths.example = ex.results
? ex.results
: webExampleN > -1
? ex.files[webExampleN]
: imgExampleN > -1 ? ex.files[imgExampleN] : null;
? ex.files[webExampleN]
: imgExampleN > -1 ? ex.files[imgExampleN] : null;

//Make thumbnails
var imgs = ex.files
Expand Down
4 changes: 2 additions & 2 deletions util/web/build/vizLibrary.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ var vizLibrary = function () {
Takes an array of metadata object (see sample input) and
a valid css selector (`parentDiv`) and renders divs
styled for for the example gallery (see sample output)
Sample Input for `meta`:
Sample Input for `meta`:
[
{
"id":"0001-density-lattice",
Expand All @@ -62,7 +62,7 @@ var vizLibrary = function () {
},
... //add more objects here as desired
]
Sample Output rendered to DOM (one per object in meta:
Sample Output rendered to DOM (one per object in meta:
<div class="media-tile">
<a href="./examples/0001-density-lattice">
<img src="./examples/0001-density-lattice/thumbnail.png" width="300" height="200" alt="0001-density-lattice">
Expand Down
135 changes: 71 additions & 64 deletions util/web/data/dataFiles.js
Original file line number Diff line number Diff line change
@@ -1,215 +1,222 @@
var dataFiles = [
{
local_path: "F:/GitHub/viz-library/data/cars.csv",
filename: "cars.csv",
ext: "csv",
rel_path: "./data/cars.csv",
rows: 32,
cols: 12
},
{
local_path: "F:/GitHub/viz-library/data/ChickWeight.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/ChickWeight.csv",
filename: "ChickWeight.csv",
ext: "csv",
rel_path: "./data/ChickWeight.csv",
rows: 578,
cols: 5
},
{
local_path: "F:/GitHub/viz-library/data/climate_data.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/cars.csv",
filename: "cars.csv",
ext: "csv",
rel_path: "./data/cars.csv",
rows: 32,
cols: 12
},
{
local_path: "/Users/jwildfire/Sites/github/viz-library/data/climate_data.csv",
filename: "climate_data.csv",
ext: "csv",
rel_path: "./data/climate_data.csv",
rows: 95,
cols: 10
},
{
local_path: "F:/GitHub/viz-library/data/discrete_scores.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/discrete_scores.csv",
filename: "discrete_scores.csv",
ext: "csv",
rel_path: "./data/discrete_scores.csv",
rows: 78,
cols: 2
},
{
local_path: "F:/GitHub/viz-library/data/hys_law.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/elements.csv",
filename: "elements.csv",
ext: "csv",
rel_path: "./data/elements.csv",
rows: 103,
cols: 10
},
{
local_path: "/Users/jwildfire/Sites/github/viz-library/data/hys_law.csv",
filename: "hys_law.csv",
ext: "csv",
rel_path: "./data/hys_law.csv",
rows: 320,
cols: 18
},
{
local_path: "F:/GitHub/viz-library/data/iris.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/iris.csv",
filename: "iris.csv",
ext: "csv",
rel_path: "./data/iris.csv",
rows: 150,
cols: 5
},
{
local_path: "F:/GitHub/viz-library/data/elements.csv",
filename: "elements.csv",
ext: "csv",
rel_path: "./data/elements.csv",
rows: 103,
cols: 10
},
{
local_path: "F:/GitHub/viz-library/data/queries/queries.csv",
filename: "queries.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/queries/fields.csv",
filename: "fields.csv",
ext: "csv",
rel_path: "./data/queries/queries.csv",
rows: 5000,
cols: 11
rel_path: "./data/queries/fields.csv",
rows: 55,
cols: 3
},
{
local_path: "F:/GitHub/viz-library/data/queries/forms.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/queries/forms.csv",
filename: "forms.csv",
ext: "csv",
rel_path: "./data/queries/forms.csv",
rows: 11,
cols: 2
},
{
local_path: "F:/GitHub/viz-library/data/queries/fields.csv",
filename: "fields.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/queries/queries.csv",
filename: "queries.csv",
ext: "csv",
rel_path: "./data/queries/fields.csv",
rows: 55,
cols: 3
rel_path: "./data/queries/queries.csv",
rows: 5000,
cols: 11
},
{
local_path: "F:/GitHub/viz-library/data/safetyData-queries/ADAE.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData-queries/ADAE.csv",
filename: "ADAE.csv",
ext: "csv",
rel_path: "./data/safetyData-queries/ADAE.csv",
rows: 402,
cols: 23
},
{
local_path: "F:/GitHub/viz-library/data/safetyData-queries/ADBDS.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData-queries/ADBDS.csv",
filename: "ADBDS.csv",
ext: "csv",
rel_path: "./data/safetyData-queries/ADBDS.csv",
rows: 22695,
cols: 20
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/ADAE.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/testData/ADTIMELINES_missingAdded.csv",
filename: "ADTIMELINES_missingAdded.csv",
ext: "csv",
rel_path: "./data/testData/ADTIMELINES_missingAdded.csv",
rows: 1067,
cols: 17
},
{
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/ADAE.csv",
filename: "ADAE.csv",
ext: "csv",
rel_path: "./data/safetyData/ADAE.csv",
rows: 392,
cols: 23
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/ADTIMELINES.csv",
filename: "ADTIMELINES.csv",
ext: "csv",
rel_path: "./data/safetyData/ADTIMELINES.csv",
rows: 1067,
cols: 17
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/ADBDS.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/ADBDS.csv",
filename: "ADBDS.csv",
ext: "csv",
rel_path: "./data/safetyData/ADBDS.csv",
rows: 22695,
cols: 19
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/ADCM.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/ADCM.csv",
filename: "ADCM.csv",
ext: "csv",
rel_path: "./data/safetyData/ADCM.csv",
rows: 337,
cols: 21
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/SDTM/AE.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/ADTIMELINES.csv",
filename: "ADTIMELINES.csv",
ext: "csv",
rel_path: "./data/safetyData/ADTIMELINES.csv",
rows: 1067,
cols: 17
},
{
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/SDTM/AE.csv",
filename: "AE.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/AE.csv",
rows: 356,
cols: 15
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/SDTM/CM.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/SDTM/CM.csv",
filename: "CM.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/CM.csv",
rows: 291,
cols: 13
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/SDTM/DM.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/SDTM/DM.csv",
filename: "DM.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/DM.csv",
rows: 150,
cols: 9
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/SDTM/LB.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/SDTM/LB.csv",
filename: "LB.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/LB.csv",
rows: 17280,
cols: 11
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/SDTM/VS.csv",
filename: "VS.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/VS.csv",
rows: 5400,
cols: 11
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/SDTM/SV.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/SDTM/SV.csv",
filename: "SV.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/SV.csv",
rows: 1080,
cols: 5
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/raw/adverseEvents.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/SDTM/VS.csv",
filename: "VS.csv",
ext: "csv",
rel_path: "./data/safetyData/SDTM/VS.csv",
rows: 5400,
cols: 11
},
{
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/raw/adverseEvents.csv",
filename: "adverseEvents.csv",
ext: "csv",
rel_path: "./data/safetyData/raw/adverseEvents.csv",
rows: 765,
cols: 4
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/raw/labs.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/raw/labs.csv",
filename: "labs.csv",
ext: "csv",
rel_path: "./data/safetyData/raw/labs.csv",
rows: 16,
cols: 6
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/raw/medications.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/raw/medications.csv",
filename: "medications.csv",
ext: "csv",
rel_path: "./data/safetyData/raw/medications.csv",
rows: 654,
cols: 3
},
{
local_path:
"F:/GitHub/viz-library/data/safetyData/raw/scheduleOfEvents.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/raw/scheduleOfEvents.csv",
filename: "scheduleOfEvents.csv",
ext: "csv",
rel_path: "./data/safetyData/raw/scheduleOfEvents.csv",
rows: 8,
cols: 4
},
{
local_path: "F:/GitHub/viz-library/data/safetyData/raw/vitalSigns.csv",
local_path: "/Users/jwildfire/Sites/github/viz-library/data/safetyData/raw/vitalSigns.csv",
filename: "vitalSigns.csv",
ext: "csv",
rel_path: "./data/safetyData/raw/vitalSigns.csv",
Expand Down
Loading

0 comments on commit e8eacd1

Please sign in to comment.