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

Option to scale and center counts #113

Open
mccalluc opened this issue Jan 11, 2018 · 3 comments
Open

Option to scale and center counts #113

mccalluc opened this issue Jan 11, 2018 · 3 comments
Milestone

Comments

@mccalluc
Copy link
Member

From Geoff:

One motivating example for centering/scaling is 2 genes that behave similarly (i.e. go up/down) to the various conditions, but, at baseline, there's a lot of one and only a little of the other in the cell. The color intensities would be different between these 2 rows based on high vs low counts, but people are often interested in groups of genes that behave similarly (could mean the genes belong to the same cellular pathway).

I believe centering/scaling is done as stated in the scale doc (https://stat.ethz.ch/R-manual/R-devel/library/base/html/scale.html) I linked to (pasting sections here):
If center is TRUE then centering is done by subtracting the column means (omitting NAs) of x from their corresponding columns
If scale is TRUE then scaling is done by dividing the (centered) columns of x by their standard deviations if center is TRUE, and the root mean square otherwise.

In the example I gave above, you would actually want to center/scale by rows (not columns). Anyway, all of that to say -- is this possible in Plotly?

@mccalluc
Copy link
Member Author

Folks in core emphasized row-scaling.

@mccalluc mccalluc added this to the Release 1.6.3 milestone Jan 29, 2018
@mccalluc mccalluc self-assigned this Jan 29, 2018
@mccalluc
Copy link
Member Author

Covered by #167... except I want to disable/grey-out log scale if either the original or derived data includes negative values.

@mccalluc
Copy link
Member Author

@gmnelson or @scottx611x : I think that having one control depend on the state of another could be confusing, and hard to implement. As an alternative, get rid of the separate "Center and Scale" section, and instead add to the "Scale" menu. It currently has the choices

  • log
  • linear

Add to those a third option

  • rescaled

This would apply a linear scale on the heatmap and the axes, and would additionally scale and center the data. Sound ok?

@mccalluc mccalluc removed their assignment Jan 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant