Displaying 20 results from an estimated 1000 matches similar to: "ggplot2 help/suggestions needed"
2010 Oct 18
2
Question about Density Plot
Hi
I've attached an example about something I want to do in R. This example
was done in a Fortran application called ASGL. Here's an example in
matplotlib
http://matplotlib.sourceforge.net/examples/pylab_examples/hexbin_demo.html
Basically, it's like a scatter plot, but have several additional things.
One thing are the grids inside the graph, and the other is a density bar
used
2011 Dec 09
3
ggplot with geom_tile
Dear R-users,
I am trying to make a plot with ggplot-geom_tile(), but cannot remove some unwanted (white) lines through my plot.
Below a reproducible example:
#####
library(ggplot2)
tot=as.data.frame(rep(seq(-50,50,5),each=21))
names(tot)="precip"
temp=rep(seq(-5,5,0.5),21)
tot$temp=temp
disc=array(dim=c(21,21))
for(i in 1:21){
for(y in 1:21){
temp<-
2008 Jul 12
1
Intergraph SmartSketch 5.00.21 on wine
Hi everybody,
I'm tying to make this design program run through wine on a ubuntu hardy 8.04.
After some struggling and getting dlls I got the installation end properly (at least it seems so), but when I try to launch the program from the programs menu I get a tiny window saying:
"gstart
Run-time error 380 Invalid Property value"
If I run the program from a terminal I get:
Code:
2010 Nov 20
2
Merge two ggplots
Hello everyone.
I am using ggplot and I need some help to merge these two plots into one.
plot_CR<-function(x,y,agentid,CRagent){
library(ggplot2)
agent<-CRagent[[agentid]] # To make following expression shorter
ggplot((data.frame(x=CRX,y=CRY,sr=agent$sr)))+
geom_point(aes(x,y,colour=cut(sr,c(0,-10,-20,-30,-40,-50,-60,-70,-80))))+
geom_text(aes(x,y,color=cut(sr,
2007 Dec 13
2
use ggplot in a function to which a column name is given
Hi everyone, Hi ggplot users in particular,
ggplot makes it very easy to plot things given their names when you
use it interactively (and therefore can provide the names of the
columns).
qplot(x,foo,data=A) where A has columns (x,y,foo,bar) for example
but I would like to use this from inside a function to which the name
of the column is given. I cannot find an elegant way to make this
2011 Aug 31
2
ggplot2 to create a "square" plot
Dear all,
I am using ggplot with geom_tile to print as an image a matrix I have. My matrix is a squared one of 512*512 cells.
The code that does that is written below
> print(v + geom_tile(aes(fill=dB))+ opts(axis.text.x=theme_text(size=20),axis.text.y=theme_text(size=20), axis.title.x=theme_text(size=25) , axis.title.y=theme_text(size=25), legend.title=theme_text(size=25,hjust=-0.4) ,
2008 Feb 05
2
using image to show RGB image data ?
Hello all,
I'm now using image() to show image data (in my case dumps of SOM
weights) but would like to show RGB colour data, not just single "z"
colour values.
I've currently been using seq() to skip 4 values, so I can show the R, G
or B channels separately as "z". But is there a way I can show all three
channels simultaneously as a proper colour image?
Thanks,
B.
2007 Jul 13
1
Choosing the number of colour breaks in ggplot2
A seemingly simple problem has me stumped. Is it possible to choose the
number of colour breaks for a gradient scale in the current version of
ggplot2?
Here is a simple example:
---------------------------------------------
x=-10:10
y=-10:10
dat=expand.grid(x=x,y=y)
dat$z=dat$x^2+dat$y^2-100
ggplot(dat, mapping=aes(x=x, y=y, fill=z)) +
geom_tile() + scale_fill_gradient2()
2011 Jul 15
2
plot a vertical column of colored rectangles
Hi, I've been really struggling with this.
If I have a vector like
dat <- c(0,0,0,0,1,1,1,0,0,0,1,1,0,0,0,1,0,0,0)
I want to plot each element as a colored rectangle (red=1, blue=1) in the
right order, so they all stack up forming a vertical column on the graph.
Sort of like a building, with each floor in the appropriate color.
Any ideas?
I've tried using ggplot and geom_tile, but my
2010 Feb 04
2
ggplot2 / time series with different scales
I am trying to plot this dataset using ggplot2:
df <- data.frame(
sid = c(rep('11',30),rep('22',30)),
time = rep(ISOdate(year = 2010, month = 1, day = 1:30),2),
sales = c(rnorm(30, 1000, 20),rnorm(30, 900, 10)),
price = c(rnorm(30, 2, 0.5),rnorm(30, 3,0.5))
)
Plotting just the sales can be done easily:
ggplot(data=df, aes(x=time, y=sales, group=sid, color=sid)) +
2009 Mar 05
1
Using vectors of names in calls for functions
Dear R people,
it is a pleasure to try and use functionnalities that are in ggplot,
even with my poor capacities in R. so far, i'dlike to be able to use
these in my own function, and to
"be able to use it repeatedly from
vectors where I store the names of my columns."
I have understood that this is a very discussed topic, that many post
have been exhanged but I cannot understand
2017 Dec 20
2
outlining (highlighting) pixels in ggplot2
Using the small reproducible example below, I'd like to know if one can
somehow use the matrix "sig" (defined below) to add a black outline (with
lwd=2) to all pixels with a corresponding value of 1 in the matrix 'sig'?
So for example, in the ggplot2 plot below, the pixel located at [1,3] would
be outlined by a black square since the value at sig[1,3] == 1. This is my
first
2011 Nov 08
3
ggplot2 reorder factors for faceting
Dear List
I am trying to draw a heatmap using ggplot2. In this heatmap I have faceted my data by 'infection' of which I have four. These four infections break down into two types and I would like to reorder the 'infection' column of my data to reflect this.
Toy example below:
library(ggplot2)
# test data for ggplot reordering
genes <- (rep (c(rep('a',4),
2020 Apr 29
2
problem with `viridis` on Ubuntu 20.04
I've hit a bug on Ubuntu 20.04. The issue occurred both with the R
version that shipped with Ubuntu last week, and it is occurring now with
the CRAN packages from one of the mirros (deb
http://cran.mirror.garr.it/mirrors/CRAN/bin/linux/ubuntu/
focal-cran40/). The issue occurs whether I use the deb package for
viridis in the Ubuntu repos, or I install it with `install.packages()` in R.
2004 Sep 09
3
Polycom IP500 vs Cisco 7940
Hi Everyone,
I've been asked to determine which phones our organization should go
with. And I've narrowed it down to the Polycom IP500 or the Cisco 7940.
From my travels through google, it's hard to find a definitive
comparison of the two phones. So I thought I would ask the people that
have probably used both.
From what I can tell, the only major benefit the Cisco has over the
2011 Aug 02
3
Clean up a scatterplot with too much data
I'm working with a lot of data right now, but I'm new to R, and not very good
with it, hence my request for help. What type of graph could I use to
straighten out things like...
http://r.789695.n4.nabble.com/file/n3711389/Untitled.png
...this?
I want to see general frequencies. Should I use something like a 3D
histogram, or is there an easier way like, say, shading? I'm sure these
2006 Aug 16
3
Gigabyte recent bios & syslinux extlinux trow USB-IDE bridges or pendrives
Hello list, I'm having problems with newest BIOS updates from Gigabyte to my
Mother Boards, they don't want to boot syslinux, extlinux y usb-hdd mode.
Then I need to know if someone else are having same problem, and can send me
the Mother Board versions and bios versions to report as a bios bug.
this is from the support, I'm awaiting for answer.
2009 May 18
4
Possibility to porting Rsync to NT and other platforms
Hello,
I am looking into possibilities of porting RSync for windows. Does anybody
have an idea that which libraries and dependencies RSync uses which can not
be compiled on windows (so thats why we use cygwin)
Regards
Hasanat Kazmi
--
Hasanatkazmi@gmail.com
"I hate Capitalism,so naturally I love Open Source" -- Hasanat Kazmi
+923464362473
-------------- next part --------------
HTML
2011 May 10
1
ggplot2 and add circle
Dear all,
today I have writted the following code,
to plot the contents of some matrices I have
plot_shad_f
function(f){
library(ggplot2)
dev.new()
plotdata<-melt(f)
names(plotdata)<-c('x','y','z')
v<-ggplot(plotdata, aes(x, y, z = z))
print(v + geom_tile(aes(fill=z)))
}
I would like to ask your help add a small circle in this plotting. What would be
2010 Jul 10
3
a very particular plot
Hi all,
Thanks for the really great help I've received on this board in the past.
I have a very particular graph that I'm trying to plot, and I'm not really
sure how to do it. I think I should be able to use ggplot for this, but I'm
not really sure how.
I have a data.frame which contains fifty sub frames containing one hundred
data points each.
I can do a histogram of each of