Questions tagged [gplots]

Various R programming tools for plotting data

gplots: Various R programming tools for plotting data

164 questions
4
votes
2 answers

How to get member of clusters from R's hclust/heatmap.2

I have the following code that perform hiearchical clustering and plot them in heatmap. library(gplots) set.seed(538) # generate data y <- matrix(rnorm(50), 10, 5, dimnames=list(paste("g", 1:10, sep=""), paste("t", 1:5, sep=""))) # the actual data…
neversaint
  • 60,904
  • 137
  • 310
  • 477
4
votes
1 answer

R - gplots - Removing white space in heatmap.2 when key=FALSE

I have: library(gplots); x<-matrix(seq(1:100),nrow=10,byrow=TRUE); heatmap.2(x, Rowv=NA, Colv=NA, scale="none", main="This title will be cut off by the white space where the non-existant key is supposed to go.", col=gray((255:0)/255),…
user2407829
  • 43
  • 1
  • 1
  • 4
4
votes
3 answers

matlab draw a graph from the incidence matrix

Is there a way to draw a graph from the Incidence matrix. By graph I mean http://en.wikipedia.org/wiki/Graph_(mathematics) not a plot. Up till now I found only how to convert incidence matrix to a adjacency matrix. In R this is possible with an…
Salvador Dali
  • 214,103
  • 147
  • 703
  • 753
3
votes
2 answers

How can I integrate these plots by putting them near each other?

I have these two plots (a heatmap and a stacked barplot). How can I put these plots near each other? Indeed I want to integrate these two plots. Thanks for any help. Here is my script: df.bar <-…
zahra abdi
  • 307
  • 2
  • 7
3
votes
0 answers

Specifying transparent color in HTML and PDF output

In an R markdown report rendered to both PDF and HTML, I would like to colorize text with different transparencies. For example, I would like to use the same orange with 3 different alpha values (0.3, 0.6, 1.0). Nicholas Hamilton provides a function…
mavericks
  • 1,005
  • 17
  • 42
3
votes
1 answer

How to add a density curve and mean line to geom_histogram?

I am currently writing my thesis and I have one thing I could not solve by searching the web. I have some datasets and I have to compare the results before and after, and I would like to visualise it by comparing two sets of histograms (both sets…
J.O.P.P.
  • 157
  • 3
  • 12
3
votes
1 answer

How to plot several seqplots (TraMineR package) using plot_grid() function in R?

I am trying to plot several plots of "state sequence object" created with the TraMineR package using the plot_grid() function. My main problem is, that I can not store the plots created with the seqplot() function in a list. My problem is not about…
MLud
  • 43
  • 6
3
votes
5 answers

Error in heatmap.2 in R gplots

I am using heatmap.2 in gplots to create heatmaps in R. My code used to work fine for creating a heatmap. But recently it started throwing errors. I am not sure why it is happening. # Matrix to feed heatmap.2 mat = as.matrix(sort_pkmat) # color…
Peeyush Sahu
  • 111
  • 3
  • 9
3
votes
2 answers

How to generate a sequence including NA values in R?

I want to know how to generate an automatized sequence from 0 to 100, with numbers each 5 positions only, all the rest should be NA values. At the end I would like to have something like this: > labCol [1] 0 NA NA NA NA 5 NA NA NA NA 10 NA NA NA…
Darwin PC
  • 871
  • 3
  • 23
  • 34
3
votes
1 answer

R heatmap.2 skip column or row labels

I am trying to plot a matrix of values over a range using heatmap.2. The columns are the range (for example, 0 to 100). There are too many column labels to display clearly. Is there a way to display every Nth one (0, 10, 20, etc)? I want all the…
burger
  • 5,683
  • 9
  • 40
  • 63
3
votes
1 answer

R: Changing the size of a heatmap.2 rowname column

I used the following code: library("gplots") heatmap.2(assay(vsd)[ens_union,], trace = "none", density.info = "none") To produce the following heatmap: As you can see, the row labels have been cut-off (the first one should, for instance, be…
Nick
  • 2,924
  • 4
  • 36
  • 43
3
votes
1 answer

Error installing gplots

I am running R (v. 3.0.3) on OSX (v. 10.9.2). When trying to install the 'gplots' package in R studio with the following command, I get an error: > library("gplots") Error in library("gplots") : there is no package called ‘gplots’ I have seen…
jensjorda
  • 183
  • 2
  • 3
  • 10
3
votes
1 answer

Add regression line to plot (plotmeans)

My problem is that I would like to create plot with mean values and standard deviation. I found the function plotmeans in package gplots and now I would like to add a trendline to that graph. I try to do this with abline but it is not working. I…
Eco06
  • 531
  • 2
  • 8
  • 17
2
votes
1 answer

Plotting a 4 axis graph with a variable in each axis

I´m looking to make a graph that looks like this: in R. The basic idea is to have a variable on each axis and graph the interactions between those variables, is there any way to connect the axis of different plots, or to do a single graph like…
user341262
  • 21
  • 3
2
votes
2 answers

Equivalent ggplot2 alternative to gplots's balloonplot?

I really like how balloonplot generates the balloon plots with the grid, moreover it keeps the cells with value of zero but does not show the circle. Here is an example, dt <- as.table(as.matrix(mtcars[1:10,])) balloonplot(t(dt), xlab ="", ylab="",…
Ahdee
  • 4,679
  • 4
  • 34
  • 58
1
2
3
10 11