Skip to content

Commit

Permalink
No commit message
Browse files Browse the repository at this point in the history
  • Loading branch information
breck7 committed Sep 9, 2024
1 parent 9cbe510 commit b462698
Showing 1 changed file with 4 additions and 11 deletions.
15 changes: 4 additions & 11 deletions pages/explore.scroll
Original file line number Diff line number Diff line change
@@ -1,13 +1,3 @@
replaceNodejs
const lodash = require("lodash")
const data = lodash.chain(require("../cancerdb.json"))
.orderBy(['measurements'], ['desc'])
.map(row => lodash.pick(row, "id measurements type tissue mainType wikipedia website country description appeared twitter".split(" ")))
.value()
const header = lodash.keys(data[0]).join(',');
const rows = lodash.map(data, row => lodash.values(row).join(','));
const csv = [header, ...rows].join('\n ');
module.exports = {ALL : 'table\n printTable\n delimiter ,\n data\n ' + csv}
tags index
title Explore CancerDB

Expand All @@ -18,7 +8,10 @@ printTitle

endSnippet

ALL
table ../cancerdb.json
orderBy -measurements
select id measurements type wikipedia website
printTable

</div>

Expand Down

0 comments on commit b462698

Please sign in to comment.