Displaying 20 results from an estimated 10000 matches similar to: "Using jpeg() function over cgi"
2003 Jul 07
1
Xvfb and R
Hi
I have recently installed and implemented Xvfb (X virtual frame buffer) so that I can create jpegs using R over CGI (SUSE Linux 8.1 and Apache 1.3).
I have noticed that in order to do this, a file (Rplots.ps) is created in my cgi-bin directory everytime a cgi script is run. This could cause problems though as I have a multi-user system where it is possible that two different users will run
2005 Jan 05
8
Replacing all NA values in a matrix
OK, dumb question, and it is probably in the docs somewhere, but after
12 months working with R and quite a while looking at the docs, I still
don't know (or have forgotten) how to replace all NA values in a matrix
at once with some other value. I can do it column by column using
is.na(), but I can't figure out how to do it for the whole matrix. My
apologies, I am ashamed ;-)
Michael
2004 Nov 16
3
Simple plot() question
Hi
First a simple question to do with plot(). How do I change the x-axis
labels on a plot?
For example, I am plotting each row of a matrix, and I want each row to
be a line on my graph. Simple really. Eg:
plot(sg[1,], type="l")
When I do this, the x-axis is labelled 1:38, as I have 38 columns in my
matrix. When I do:
plot(sg[1,order(sg[1,])], type="l")
Ideally I would
2005 Jan 25
2
Rd problems when converting DVI version
Hi
Running R v2.0 on SuSe linux 8.2.
I'm trying to build a package (which built perfectly on Windows...) on
Linux, and I ran:
R CMD check mypackage
I got:
* checking mypackage-maual.tex ... ERROR
LaTeX errors when creating DVI version
This typically indicates Rd problems
OK, there are no problems with my Rd - I got 3 warnings but they were
all expected, and the whole package builds find
2008 Aug 05
1
Greek characters in plots
Hi
I am running an R script that creates 100s of graphs, and I need to use
the greek CAPITAL letter delta in the mtext() function.
I got as far as expression(delta) but this gives me the lowercase
version.
Can anyone help? I'm using R 2.7 on Windows XP
Mick
Head of Informatics
Institute for Animal Health
Compton
Berks
RG20 7NN
01635 578411
2004 Dec 10
4
cbind() and factors.
Hi
I'm seeing some "odd" behaviour with cbind(). My code is:
> cat <- read.table("cogs_category.txt", sep="\t", header=TRUE,
quote=NULL, colClasses="character")
> colnames(cat)
[1] "Code" "Description"
> is.factor(cat$Code)
[1] FALSE
> is.factor(cat$Description)
[1] FALSE
> is.factor(rainbow(nrow(cat)))
[1]
2004 May 19
7
Help with hclust() and plot()
Hi
When I use plot(hclust(dist..)...)...) etc to create a dendrogram of a
hierarchial cluster analysis, I end up with a vertical tree. What do I
need to do to get a horizontal tree?
Also, my users are used to seeing trees who's leaves all "end" at the
same place (eg. Like in minitab). Is this possible in R?
Thanks
Mick
Michael Watson
Head of Informatics
Institute for Animal
2004 Dec 20
3
Memory problem with jpeg() and wide jpegs
Hi
I have been creating very, very long jpeg images for the last two weeks
using jpeg(). All of a sudden, and I mean that, it's stopped working -
I've not changed a thing! The error message I get is:
> jpeg("out.jpg",width=50000,height=480, quality=100)
Error in devga(paste("jpeg:", quality, ":", filename, sep = ""), width,
:
unable
2008 Aug 07
1
Mtext doesn't display characters in italic when I use a greek symbol
Following on from my previous mail!
plot(1:10,1:10)
mtext("title", side=3, adj=0, font=3, cex=1.5)
This works as expected and puts the font in italics.
tag <- "A)"
suffix <- "genea::"
plot(1:10,1:10)
mtext(bquote(.(tag) ~ Delta * .(suffix)), side=3, adj=0, font=3,
cex=1.5)
Here, the font isn't in italics, it's normal.
I presume this is some
2003 Jul 03
1
General X11 Problems
Hi
You may remember a while ago I was having problems with creating jpegs using R over CGI. I solved this on my LAPTOP (*grins*) by
- executing "xhost +localhost" from the command line
- putting "SetEnv DISPLAY=:0.0" in my httpd.conf (apache)
And all worked well. Now I'm trying to move the whole system onto my shiny new server - and encountering yet more problems
2005 Jan 05
0
AW: Replacing all NA values in a matrix
Replacing the NA?s with eg. 1 :
> a
1 2 3 4
1 20 50 10 80
2 NA 19 NA 49
3 NA 32 NA 61
4 45 101 44 190
a[try(is.na(a)) == TRUE] <- 1
> a
1 2 3 4
1 20 50 10 80
2 1 19 1 49
3 1 32 1 61
4 45 101 44 190
I this can help you,
Matthias
> -----Urspr?ngliche Nachricht-----
> Von: r-help-bounces at stat.math.ethz.ch
> [mailto:r-help-bounces at
2004 Aug 26
5
Problems with par() and labels with boxplot
Quite a simple one really!
When I run boxplot(), the labels on the X axis are horizontal, and I
want them vertical. So I did:
par(las=3)
boxplot(...)
And my labels just aren't there anymore....
Any help???
2004 Aug 25
1
Problems with Heatmap
Hi
I am having some problems getting my heatmap to be the right size! Let
me explain. I am experienced at getting an hclust or a dendrogram
object to be the right size.
For example, I have a dataset which has 4000 rows, which I clustered
using hclust and I wanted to plot it as a horizontal dendrogram. So I
used jpeg(), set the image height to be 4000 and plotted the dendrogram
and got the
2003 Jul 25
5
R won't connect to the internet on SUSE Linux 8.1
Hi
Thanks once again for your help, I do appreciate it..... however....
Here is what I get with your test.... (under tcsh - i normally use bash, but I will keep everything the same)
users/mwatson> env http_proxy=http://wwwcache.bbsrc.ac.uk:8080/ R
>options(internet.info=0)
>update.packages()
trying URL `http://cran.r-project.org/src/contrib/PACKAGES'
unable to connect to
2006 Feb 23
7
Bug in setting GUI to SDI mode?
Hi
I did a google search on this and came up with nothing.
OK, in the latest release of R for windows, I want to change the gui to
SDI mode.
Edit -> GUI preferences
Choose SDI
Apply
I get the message about properties not being able to be changed on a
running console, and that I need to save.
So I click Save, and am met with a "Save As" dialogue box with the
default file called
2005 Feb 03
5
How to convert a list to a matrix
Hi
Sorry to ask such a basic question. I have a list, each element of
which is a vector of two values. What I actually want is a matrix with
two columns, and one row per element of the list. Obviously I have
tried as.matrix(), and as.vector() but I didn't expect the latter to
work.
I feel so lame asking this. Any suggestions?
Mick
2004 Dec 17
3
If it's not a data.frame, matrix or vector, what is it?
Hi
Forgive my ignorance. I am selecting a column of a data.frame using the
column name, and I want to know what the resulting column "is". My data
frame is called "submin" and the column name is held in a variable
called "display.gname" Eg:
> is.data.frame(submin)
[1] TRUE
> is.data.frame(submin[,display.gname])
[1] FALSE
>
2003 Jul 24
3
R won't connect to the internet on Linux!
OK, I really am struggling with this one! Forgive me if I am being stupid....
I am running R 1.7.1 on Suse Linux 8.1. I connect to the internet through a proxy so I have:
IAHC-LINUX03:~ # echo $http_proxy
wwwcache.bbsrc.ac.uk:8080
IAHC-LINUX03:~ # echo $HTTP_PROXY
wwwcache.bbsrc.ac.uk:8080
just in case ;-)
SO, i go into R and I get:
>
2005 Apr 05
5
Help with three-way anova
Hi
I have data from 12 subjects. The measurement is log(expression) of a
particular gene and can be assumed to be normally distributed. The 12
subjects are divided into the following groups:
Infected, Vaccinated, Lesions - 3 measurements
Infected, Vaccintaed, No Lesions - 2 measurements
Infected, Not Vaccinated, Lesions - 4 measurements
Uninfected, Not Vaccinated, No Lesions - 3 measurements
2004 Sep 02
3
Problems with heatmap.2
Hi
When I give the command:
>
heatmap.2(as.matrix(d),Rowv=as.dendrogram(hc.gene),Colv=FALSE,scale="row
",trace="none",col=greenred.colors(79))
The resulting heatmap has re-ordered my columns! This is time-course
data, and I don't want my columns re-ordered! Note from the help:
Rowv: determines if and how the _row_ dendrogram should be
reordered.