Displaying 20 results from an estimated 20000 matches similar to: "Automatic adjustment of axis ranges"
2007 Mar 07
2
Multi-line plots with matrices in R
Hello all,
I'm a new user of R, experienced with Octave/MATLAB and therefore
struggling a bit with the new syntax.
One of the easy things in Octave or MATLAB is to plot multiple lines or
sets of points by using a matrix where either the columns or the rows
contain the y-values to be plotted. Both packages automatically give
each line/points their own unique colour, character etc.
I'm
2001 Aug 02
1
gsub() and parenthesis symbols
Dear R-users --
I'm using R 1.3.0 on a PC running SuSE Linux 7.1. I'm confused by the
following behavior from the gsub() function. Am I doing something wrong?
## A string of characters
> string<-c("q","w","e","(",")","q","w","e")
## Use gsub to replace `q' with `A'
>
2018 Mar 05
1
Unclosed parenthesis in grep.Rd
There are probably more unmatched parentheses around:
detect <- function(file) {
text <- paste(readLines(file), collapse = "")
nchar(gsub("[^(]", "", text)) != nchar(gsub("[^)]", "", text))
}
docs <- list.files("r-source-trunk/src/library",
pattern = "\\.Rd$",
full.names =
2005 Jan 11
2
Changing the ranges for the axis in image()
Dear all,
I can not find/understand the solution to this from the help pages:
Say we have the following script:
x<-matrix(c(1,1,0,1,0,1,0,1,1),3,3)
image(x)
How can I change the ranges on the vertical and horizontal axis to a
range of my own or at least place a box frame around the image if I
choose to use "axes=FALSE"?
Apologies for such a bsic question and thanks beforehand
2009 Oct 09
2
Problems with code containing a for loop
The following code isn't working and we can't figure out why..
letters = c("A","B","C","D","E","F","G","H","I","J")
numbers = 1:3
for(i in 1:6){ #6 letters
for (j in 1:3) { #3 numbers
for (k in -1:1) {
2007 Mar 23
3
distribution graph
I am looking for a way to produce a "distribution graph" as in the example:
(http://cecsweb.dartmouth.edu/release1.1/datatools/dgraph.php?year=2003&geotype=STD_HRR&event=A01_DIS&eventtype=UTIL
Anybody who can help?
Christian von Plessen
Department of Pulmonary Medicine
Haukeland university hospital
Bergen
Norway
2007 Aug 30
1
Barplot2 using for loop, how to adjust margins?
Hi R-users,
I inted to make multiple plots using for loop. The question is how can
I adjust the left hand side margin of the plot according to the
names.arg argument in barplot2. In every plot I have different
annotations in the y axis and they vary in length. Now when I have
fixed margins
opar <- par(mar=c(3,15,0,2)...
I get the same margins in all of the plots. That leaves lots of white
2008 Jun 11
1
specifying ranges in scatter plot
Hi, there:
Does anyone know how to specify the ranges in the axises when I make
scatter plots using pairs()? In the general plot function, I can use
xlim and ylim option. But how can I do this if I use pairs()?
Thanks.
Yulei
[[alternative HTML version deleted]]
2008 Oct 20
2
R Newbie Question
Hello list,
I just started R today and tried something quite simple. I wanted to
create a colored plot and eventually after hours of fiddling around got
it working. However, my solution seems very suboptimal and I'd really
appreciate your hints on how to improve. I believe that R already offers
many functions I coded (e.g. distance between two vectors, vector
length, vector normalization and
2009 Jul 14
5
plotting confidence intervals
Hi R People:
If I have a fitted values from a model, how do I plot the
(1-alpha)100% confidence intervals along with the fitted values,
please?
Also, if the intervals are "shaded" gray, that would be nice too, please?
I check confint, but that doesn't seem to do what I want.
Thanks in advance,
Sincerely,
Erin
--
Erin Hodgess
Associate Professor
Department of Computer and
2008 Jan 24
1
adjustment on the x-axis scale width
Hi,
I have sucessfully plotted the graph by using the following command:
ec<-rep(0,length(e))
fc<-rep(0,length(f))
plot(e,ec,type="p",col=1,pch=19)
points(f,fc,col=2,pch=20)
legend(1.0e+08,1.0,c("dog", "human"),text.col="green4",pch=c(19,20),col=c(1,2))
Below are the values for e and f...the questions is how am i going to adjust
2017 Jul 28
3
Superscript and subscrib R for legend x-axis and y-axis and colour different subjects in longitudinal data with different colours
I am trying to make a x-axis and y-axis titles with both a special character and a subscript. I am not being able to do this. I think its just a placing of my parenthesis, but I've tried (seemingly) everything.
Even more, when I try the blog users code it works.
Is it because I?m using longitudinal data?
Even more. Is it possible to colour each one of the 15 lines with a different
2005 Dec 15
5
Action Mailer - connection refused - connect(2)
hi:
I am on Mac OSX 10.4 using locomotive.
My ActionMailer configuration is
ActionMailer::Base.delivery_method = :smtp # or :sendmail or test
ActionMailer::Base.server_settings = {
:address => "mail.albertafilmworks.com",
:port => 25,
:domain => "brucebalmercanada.com"
}
ActionMailer::Base.perform_deliveries = true
2002 Jan 18
3
readline() to vector
Hi!
I'm trying to use readline() to ask for xlim() and ylim() values
for a subsequent plot. I'm doing:
lim <- readline("Enter xlim and ylim values: ")
then would like to use the values in lim for a plot:
plot(etc, xlim=lim[1:2],ylim=lim[3:4])
The problem is that lim is a character,i.e.,
"10,20,-10,50"
or
"c(10,20,-10,50)"
depending on the input to
2020 Mar 30
2
Plotmath on Fedora 31 broken with with pango >= 1.44 - workarounds?
Le mardi 31 mars 2020 ? 10:14 +1300, Paul Murrell a ?crit :
> Hi
>
> On 30/03/20 11:12 pm, Nicolas Mailhot wrote:
> > Le lundi 30 mars 2020 ? 15:24 +1300, Paul Murrell a ?crit :
> > > Hi
> > >
> > > I have created an R branch that contains a potential fix ...
> > >
> > > https://svn.r-project.org/R/branches/R-symfam/
> > >
2008 Oct 23
15
VEC Operator in R
Can anyone please tell whether there is any R function to act as "VEC" and
"VECH" operator on Matrix? Yes of course, I can write a
user-defined-function for that or else, I can put dim(mat) <- NULL. However
I am looking for some R function.
Your help will be highly appreciated.
Regards,
--
View this message in context:
2010 Aug 31
4
How to Adaptively Set Up the Coordinate Range of Multiple Graphs in One Figure
Hi, R-Helpers,
I would like to ask about multiple graphs in one figure. I tried to execute
the following codes.
xlim <- c(1,100)
ylim <- c(1,4)
plot(NA, xlim=xlim, ylim=ylim)
> x <- c(1:100)
for(j in seq(1,10,by=1)) {
y <- j*x^2+log(j)
lines(x, y)
}
In the above codes, I had to arbitrarily set up the coordinate range of the
figure in advance before
2007 Jan 23
6
can't plot a line
Consider the following:
plot(0, 0, xlim=c(-10, 10), ylim=c(-50, 50))
lines(c(0,0), (2*c(-pi, pi))^2)
I see no line in this plot.
R version 2.4.1 (2006-12-18)
i386-pc-mingw32
locale:
LC_COLLATE=English_United States.1252;LC_CTYPE=English_United
States.1252;LC_MONETARY=English_United
States.1252;LC_NUMERIC=C;LC_TIME=English_United States.1252
attached base packages:
[1]
2010 Nov 10
3
plot & xlim/ylim & range of axis
Dear mailing list readers!
Using R and the plot function I stumbled over this little issue:
plot(x=NULL,
y=NULL,
xlim=range(1:10),
ylim=range(1e-9:1),
log="y")
produces an plot empty plot, where the y-axis is in the specified range.
Changing ylim to
ylim=range(1e-9:1e-3)
creates an y-axis in the range of 1e-12 to 1e-6. This appearance of the
y-axis is a
2009 May 17
4
Can YOU find a trailing parenthesis?
On 1.6.1, I must be losing my eyesight:
[internal]
include => outbound-pstn
.............
include => meetme ; 2663
include => setup-meetme-conf-room ; 6000xxxYYYY
[setup-meetme-conf-room]
exten => _6000XXXNXXX,n,Set(Time-in-secs="${STRFTIME(${EPOCH},,%s}" )
........
CLI:
-- Starting simple switch on 'DAHDI/1-1'
[2009-05-17 14:54:49]