Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Speed up and test sample metadata barplot computations #313

Merged
merged 27 commits into from
Aug 13, 2020
Merged
Changes from 1 commit
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
ba65a87
MNT: Abstract+simplify sm barplots/getObsCountsBy
fedarko Aug 6, 2020
c0e023c
STY: prettier
fedarko Aug 6, 2020
9703416
Merge branch 'master' of https://github.com/biocore/empress into sm-b…
fedarko Aug 6, 2020
5a5479b
MNT: ++ instead of += 1 consistently in biom table
fedarko Aug 6, 2020
13e0272
MNT: document+rename getObsCountsAndTotalBy()
fedarko Aug 6, 2020
898a0b3
MNT: add sped up? freq map code
fedarko Aug 6, 2020
32174c0
STY: prettify
fedarko Aug 6, 2020
d10c4ed
MNT: use 2D arrays internally for freq map comp
fedarko Aug 7, 2020
b59ba6e
MNT: remove now-unused code i added earlier
fedarko Aug 7, 2020
e541686
STY: prettify
fedarko Aug 7, 2020
c1440e6
DOC: improve documentation for freq map #298
fedarko Aug 7, 2020
3cb4771
DOC: add extra context to sm barplot drawing func
fedarko Aug 7, 2020
65dfcc2
STY: fix redundant variable declaration
fedarko Aug 7, 2020
f08638d
TST: test getFrequencyMap() - close #298
fedarko Aug 7, 2020
e91538a
DOC: document getfrequencymap output a bit more
fedarko Aug 7, 2020
7083d67
grammar
fedarko Aug 8, 2020
3735832
Add extra freqmap test
fedarko Aug 8, 2020
1ece062
DOC: improve uniqueVal docs in sm barplot drawing
fedarko Aug 8, 2020
f685f99
TST: expand getFrequencyMap() tests
fedarko Aug 8, 2020
7890a17
Update empress/support_files/js/biom-table.js
fedarko Aug 11, 2020
2b8626d
MNT: rename remaining fIdx2... vars
fedarko Aug 11, 2020
5fa827b
MNT: fID2freqs -> fID2Freqs
fedarko Aug 11, 2020
dc6476b
DOC: more explicit about smb proportions in README
fedarko Aug 11, 2020
3aeec27
DOC: clarify presentFeatureIndices usage a bit?
fedarko Aug 11, 2020
d2b7d37
DOC: add note re a future optimization #313
fedarko Aug 11, 2020
80770a8
MNT: Simplify iteration in SM barplot drawing
fedarko Aug 11, 2020
472a248
STY: prettify
fedarko Aug 11, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
TST: test getFrequencyMap() - close #298
fedarko committed Aug 7, 2020
commit f08638d6febd9e617a7f622c538e4b37f79d0368
14 changes: 14 additions & 0 deletions tests/test-biom-table.js
Original file line number Diff line number Diff line change
@@ -690,5 +690,19 @@ require(["jquery", "underscore", "BiomTable"], function ($, _, BiomTable) {
"Test: error thrown if unrecognized metadata col passed"
);
});
test("Test getFrequencyMap", function () {
deepEqual(this.biomTable.getFrequencyMap("f1"), {
o1: { a: 1 },
o2: { a: 0.5, c: 0.5 },
o3: { a: 0.5, c: 0.5 },
o4: { a: 0.5, b: 0.5 },
o5: { a: 2 / 3, b: 1 / 3 },
o6: { a: 0.5, c: 0.5 },
o7: { a: 1 },
o8: { b: 1 },
o9: { a: 1 },
o10: { a: 1 },
});
});
});
});