-
Notifications
You must be signed in to change notification settings - Fork 40
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
Separator/break #10
Comments
It is possible to separate clusters by adding white space when you specify some larger number under "change data options" - "Number of clusters in rows" or "Number of clusters in columns". |
Thank you for getting back to me. I am using r to generate heatmaps. I am using no cluster option for columns (clustDistCols = NA) but I was wondering if it is possible to add a gap manually between columns in the heatmap to separate groups similar to (gaps_col) or (gaps_row) in pheatmap. Thanks again appreciate your help |
Thanks for the clarification. This is not possible indeed at the moment. I will think a bit what would be the best solution here. |
Thanks for your response. Actually, I was able to add the row/column gap option by modifying your original code as below. Thanks for the amazing package! Regards createHeatmap2 = function(clust, nbrClustersRows, nbrClustersCols, colorAnnoRow, colorAnnoCol, legendColorScheme, plotWidth, plotRatio, colorRangeMin, colorRangeMax, matrixColorScheme, revScheme, cellBorder, fontSizeGeneral, showNumbers, fontSizeNumbers, precisionNumbers, showRownames, fontSizeRownames, showColnames, fontSizeColnames, showAnnoTitlesRow, showAnnoTitlesCol, maxAnnoLevels,gapscol,gapsrow,cellwidth , cellheight,legend ,annotation_legend ){ #filter row annotations: #filter column annotations: #calculate default values if needed: #remove annotations with large number of levels: #image dimensions: #color scheme: #outside the specified range, set color to respective min/max color: #current implementation of pheatmap reverses the annotations: #calculate annotation colors, default ones are sometimes strange q = pheatmap::pheatmap(matFinal, ) caption = createCaption(type = "hm", info = captionInfo) generateHeatmapedited = function(proc, showImputed = TRUE, transpose = FALSE, clustDistRows = "correlation", clustMethodRows = "average", treeOrderingRows = NA, nbrClustersRows = 1, clustDistCols = "correlation", clustMethodCols = "average", treeOrderingCols = NA, nbrClustersCols = 1, colorAnnoRow = NA, colorAnnoCol = NA, legendColorScheme = "Set1", plotWidth = 25, plotRatio = 0.8, colorRangeMin = NA, colorRangeMax = NA, matrixColorScheme = "RdBu", revScheme = TRUE, cellBorder = "grey60", fontSizeGeneral = 10, showNumbers = FALSE, fontSizeNumbers = 12, precisionNumbers = 2, showRownames = TRUE, fontSizeRownames = NA, showColnames = TRUE, fontSizeColnames = NA, showAnnoTitlesRow = TRUE, showAnnoTitlesCol = TRUE, maxAnnoLevels = 50,gapscol=NULL,gapsrow=NULL,cellwidth = NA, cellheight = NA,legend = TRUE,annotation_legend=TRUE){ |
I added ellipsis to make it possible to pass custom parameters to pheatmap function: 73e8d66 This is a more general solution and it is now possible to call generateHeatmap function like this: |
would it be possible to add a horizontal/vertical line at a specific position in the heatmap to separate groups? something similar to rowsep or colsep in heatmap.2
Thank you in advance for your help!
The text was updated successfully, but these errors were encountered: