Fixes https://github.com/chanzuckerberg/cellxgene/issues/1349
For more information see https://github.com/d3/d3-format
Note that does not _fully_ fix the issue described in #1349, but rather
makes the formatting issue far less likely. It is _still_ possible for
this to occur if the difference between two ticks in axes happes in the
a significant digit cropped by the scientific notation format
* maybe truncate string
* add string formatting to test
* correct import
* destructuring
* add maxlength
* test
* Respond to feedback from @bkmartinjr
Co-authored-by: Matt Weiden <538456+mweiden@users.noreply.github.com>
* add test labels
* prettier + add clcik return to clickOn()
* prettier + begin test
* finish label counting test
* add util to get coordinates of element
* add test id to labels
* add test to check overlay transform
* remove logs
* rename to match master
* first cut at re-embedding route and back-end support
* update and expand config route tests
* add scanpy_umap
* add reembedding to config route parameters
* front-end support for reembedding fetch and UI
* remove unused imports
* add loading state
* save reembedding in reducer state
* improve withColsFrom
* transmit reembed schema to client; pick unique embedding names
* display embeddings
* format
* lint
* spaces, tab size 2
* lint
* test hack for smoke-test race
* back out hack sleep
* add check for backed mode
* add unit test for reembedding
* lint
* hide re-embedding CLI param from help
* Undo selection appends diffExp genes to user gene list
Fixes https://github.com/chanzuckerberg/cellxgene/issues/1171
Need: When a user performs a differential expression from within
a sub-selection (world) of the data and then resets the selection to all
cells (universe), the differential expression results are no longer
valid.
Approach:
* When the selection is reset, move the top (maxUserDefinedGenes
- len(userDefinedGenes) from the differential expression results to the
list of user defined genes
* Raise maxUserDefinedGenes to 25 to give users more room and
accommodate the extra genes transferred in from differential expression
Other commits:
* Choose different button icons
* Add diff exp genes to user defined genes on subset too
* Respond to feedback from @liaprins-czi and @bkmartinjr
* Add undo/redo tests for annotations
Fixes https://github.com/chanzuckerberg/cellxgene/issues/969
... also refactor the tests for DRY.
* Add done()
* Make e2e annotations tests safer to concurrency
* Add data-testclass for save state.
* Simplify tests and make them dependent on save state
* Add smoke test for annotations features
* Do not save during annotations tests
* Fix botched rebase in dev guidelines
* Revert "Do not save during annotations tests"
This reverts commit f0bd970bb2.
* Respond to feedback from @bkmartinjr
* Collect all env vars in one, easy-to-find place
Past state:
* Default environement variables were stored in both client/package.json
and client/__tests__/e2e/config.js
* Constants that should have been linked--like the cellxgene server port
during testing--were repeated.
With this commit:
* All environment variables are parameterized
* All environment variables are packaged in default env files
* Move npm scripts to client Makefile
* Respond to feedback from @seve and @bkmartinjr
* load annotations individually
* fix type check to be more general
* update node CI version from 10 to 12
* node 11
* debug print node version
* travis node version to latest
* try nvm
* remove extraneous node_js statement
* remove node version debugging printf
* incrementally load all annotations and layout
* process annotations and layout as they are loaded
* fix tests
* sort categories incrementally
* incrementally build category view summary; add category loading spinner
* add spinner to continuous metadata
* configure undoable reducer
* incremental crossfilter creation
* improve busy layout
* more layout cleanup
* correctly reconcile categories in schema
* refine layout of lsb spinners
* more spinner layout work
* more spinner layout
* always load layout before obs annotations
* Create right sidebar files, move histos over
* restructure continuous legend + all padding
* right sidebar file
* proper graph positioning and resize
* new lasso values since right sidebar
* fix autosave position
* freeze objects
* component rendering perf work
* use PureComponent where safe
* remove obsolete WorldUtil code
* make brushable histogram a pure component
* many graph/scatterplot fixes: 722, 882, 758, 886
* fix e2e test breakage caused by graph transform work
* convert webgl point shaders to use flags rather than explicit point size
* remove unused packages from dependencies
* fix typo in regl prop name
* factor common code into util helper file
* legibility tweaks
* comment
* add histogram functionality to Dataframe; port category occupancy to use it
* fix binning and create histogram for continous by catagorical
* Remove unnecessary logs
* Begin work on KDE
* Replace broken KDE with working histogram
* Define domain and range based on data from histogram
* Fix occupancy
* Add continuous obs and switch to canvas
* Stop value from always rerendering
* clear before render
* Clear canvas on render
* refactor categorical occupancy to canvas
* Remove log
* simplify finding max
* refactor kde->histogram and occupancy->bins
* refactor svg -> canvas
* rename to occupancy stack
* create popup
* add metadata and categorical values to popup
* fix overflow
* remove zeros info
* style graph
* fix shouldComponentUpdate to look for world changes
* change categorySelected -> categoryValueSelected
* refactor out render
* remove comment
* conditionally have bottom border
* remove diff comp
* remove comments
* remove unnecessary mapping
* Add comments describing drawing functions
* comments
* flip comparison order
* remove logging
* move default to parameter
* move defaults to parameter
* disable popover if not showing histogram
* fix wording and styling
* add line break
* menubar 1
* zoom switching
* centering, pixel perfect canvas
* remove dead args and code
* clipping
* remove log
* if
* connect props
* lint
* undo
* logo left, componetize
* graph back to full height
* shadow to top
* do not prematurely call event handlers during render
* change test to deal with async histogram creation
* left section padding
* lint
* adjust graph to account for top bar,
* lasso tests
* refine histogram tests
* remove testing (onlys)
* enforce column name uniqueness for obs and var
* parameterize the column name containing obs and var user-readable names
* use the new annotation index value from schema
* update f/e unit tests
* PR review suggestions
* lint
* change pan speed to 1 per issue #722
* correct handle scaling of graph when aspect ratio less than one
* add package lock
* add invert to our scale functions
* correctly transform to/from gl coordinates
* remove unused import
* fix naming of import
* update smoke tests
* add own range() function
* lodash cleanup
* remove redundant fill range implementations
* remove use of _.get
* sync test babel config with build
* update tests to match new range implementation
* Add numeric inputs for percentiles
* Define initial values for percentile cutoffs in world reducer
* add percentil to crossfilter dimensions
* worldEqUniverse now handles cloned worlds
* add Dataframe.mapColumns
* Wire up handlers for percentile inputs
* World reducer and stateManager know about continuousPercentileMin/Max
* Create world as universe clone (not pointer) to avoid clobbering vals
* Define basic actions for setting continuousPercentileMin/Max
* Under the hood, deal with percentiles between 0 and 1
* Move percentile inputs to visualization settings menu
* Fix padding for undo/redo buttons
* Trigger world rebuild from percentile actions
* BROKEN - pseudocode for clamping dataframe by percentiles upon world rebuild
* fix error handling on clip quantiles; start world clipping implementation
* more unclipped reorg
* rename crossfilter.percentile to quantile
* simplify schema access
* update continuous legend when scale changes
* update color cache when clip changes
* clip obs annotations and var data when clip quantile changes
* use own fromEntries
* fix tests
* stable non-finite float sort/search
* clarify comments
* fix syntax typo
* use new stand-alone clip
* clip expresssion data
* add select tests for non-finite scalars
* basic styles
* clip UI now requires explicit commit
* reset enable/disable accounts for clip percentiles
* better error messages
* fix bug in undo interaction with programatic min brush selection
* small refactoring
* support clipping of int data
* do not perform unnecessary summarizations
* improve caching of dataframe compiled columns
* add percentile precompute to Dataframe.summarize
* use Dataframe.summarize for clip percentiles
* remove obsolete quantile code from corssfilter
* histogram scale and label Y axis, add unclipped X range labels
* layout tweaks
* scatterplot now updates when clip changes
* improve comments
* remove debugging comment
* rework clip number entry validation for usability
* ui tweaks to histogram colors and layout
* enable undo/redo for clip user action
* refine UI on clip value entry
* api cleanup
* update confusing comment
* clarify purpose of isValidDigitKeyEvent
* fix misleading comment
* apply appropriate button-group classes; do not mix span and div
* variable name and comment changes suggested in PR review
* rename sort to sortArray; remove unused and dead code path
* naming changes suggested in PR review
* code review improvements for clarity
* more small changes from PR review
* lint fixes for PR review
* fix spelling error
* clarify that function performs in-place modification of world
* add comment to clarify intent of range operation
* fix bad indents in comments
* clean up __columnsAccessor comments and code
* improve comments around clipPredicate
* field name consistency
* improve comment on quantiles params
* add test for color by gene expression
gene expression and metadata color by are handled differently
* error on console.error
not just on thrown errors
* save graph selection in redux state
* fix old graph brush select regressions
* refactor graph brush selection to work with undo/redo
* update tests to match new crossfilter spatial select API
* graph selection state now in redux
* remove dead code
* sync graph selection with redux state; improvements to undoable machinery
* fix regression in undoable
* differentiate graph selection cancel from deselect action
* simplify calculation
* remove debugging code
* fix responsive repaint bug in graph selection tool
* undoable debugging and code cleanliness
* undoable action filter state now merges, rather than replaces
* improve comments
* add debounce to undoable action filter; improve comments and debug sanity check code
* comments
* fix undoable bug with clear scatterplot actions
* disable undoable debug flag
* cleanup API and comments around statemachine
* add test id attribute to lasso
* add better error handling for gene fetch requests
* immutable crossfilter
* first cut at reducer refactor with cascade model
* add initial redo/undo implementation
* small optimization
* integrate expression with history
* add tests for new reducers and fix a couple of small initialization bugs
* treat tiny lasso selections as a clear
* better function name for clarity
* fix undo for differential expression
* remove logging
* fix regression due to bad merge
* cleanup and comments for clarity
* improve undoable configuration for flexibility
* fix stale comments
* remove debugging code from production build
* rename categoricalSelectionState
* rename file
* improve comments
* initial dataframe commit
* initial dataframe port of core app
* rename variables for clarity
* remove unused import
* comment out unused code
* fix array handling bug in crossfilter dimension creation
* allow creation of empty dataframes
* handle non-existent columns
* handle non-existent columns
* revise tests for new dataframe
* comments for clarity
* comments for clarity
* generate bulk add placeholder with real gene names
* fix bug in gene name adding
* more dataframe unit tests
* fix bug - subset from current world, not universe
* put cut and pasted code into a single function
* improve caching of crossfilter
* remove cascading update bug from graph
* more performance work
* improve state handling for scatterplot
* performance optimization of critical path
* add column summarization
* dataframe utils
* add callOnceLazy
* fix tests
* minor updates found during review
* fix misspelling
* remove RESTv02 from function names
* comment cleanup
* cut/icut col parameter defaults to null
* break up large test
* improve tests and comments on dataframe at/has functions
* add Dataframe withCol/dropCol
* expression varData now stored in a dataframe
* dead code cleanup
* use dataframe.summarize()
* test cases for Dataframe.col.summarize
* update test cases for new dataframe summarize
* improve naming
* use new hasCol API
* add comments
* add more Dataframe.withCol tests
* add ability to specify row index in cut operation
* retire subsetVarData function
* correctly handle expression subsetting
* lint and improve comments
* rename cut to subset
* changes based on PR review
* initial dataframe commit
* initial dataframe port of core app
* rename variables for clarity
* remove unused import
* comment out unused code
* fix array handling bug in crossfilter dimension creation
* allow creation of empty dataframes
* handle non-existent columns
* handle non-existent columns
* revise tests for new dataframe
* comments for clarity
* comments for clarity
* generate bulk add placeholder with real gene names
* fix bug in gene name adding
* more dataframe unit tests
* fix bug - subset from current world, not universe
* put cut and pasted code into a single function
* improve caching of crossfilter
* remove cascading update bug from graph
* more performance work
* improve state handling for scatterplot
* performance optimization of critical path
* add column summarization
* dataframe utils
* add callOnceLazy
* fix tests
* minor updates found during review
* fix misspelling
* remove RESTv02 from function names
* comment cleanup
* cut/icut col parameter defaults to null
* break up large test
* improve tests and comments on dataframe at/has functions
* lasso working
* break out invert into own function
* action
* add spatial dimension to crossfilter, in support of polygon lasso
* improve comments on new dimension API
* lasso vs zoom
* first flatbuffer schema
* do not lint auto-generated files
* add flatbuffers package
* add flatbuffer module
* wire up /data/X/T route
* use flatbuffers for matrix data fetc
* clarity and comments
* add flatbuffer layout route
* clean up obsolete code
* fix tests
* move flake8 config to setup.cfg
* add comments
* lint
* rework layout routes for fbs
* add more type support to fbs
* lint
* add flatbuffer support for annotations
* function name improvements
* fix botched merge with master
* remove unused import
* route cleanup for flatbuffers
* rename function for clarity
* add missing globals to Jest tests
* fix client JS tests
* fix routes for Python tests
* comments for clarity
* non-finite floating point hardening
* more non-finite number handling
* lint
* fix tests for summarizeAnnotations
* harden diffexp calculation against FP errors
* cleanup unused code
* lint
* add encoding tests for flatbuffers
* application type specified as strings
* fix spelling error
* improve variable names
* add note about documentation gap
* rename FBS DataFrame to Matrix