Displaying 20 results from an estimated 1100 matches similar to: "information reduction-database management question"
2009 Apr 30
3
Curved arrows
I'm trying to draw an arrow with a curved shaft on the graph as a straight
one looks messy on a detailed graph. I've looked in arrows but it doesn't
seem to give an option. larrows doesn't look much more promising. I had a
look in the archive and couldn't find anything. Any thoughts?
Thanks
Paul
--
View this message in context:
2010 Jan 25
3
Paste expression in graph title
This was my initial attempt at creating a title on a graph of the R squared
value:
x<-rnorm(10)
y<-rnorm(10)
plot(x,y, main=paste(expression(R^2)," = ",round(summary(lm(y~
x))$r.squared, digits=3), sep=""))
I've read various other posts that say expression needs to be taken outside
the paste, but I can't seem to get it work as the following fails
plot(x,y,
2010 Jun 09
2
Read in dataset without saving it
A simple question - I have a small dataset to read in and want to copy and
paste part from Excel and paste it into an R script file without creating
more files saving it as a .txt/.csv and then reading that in. I want to
read in 3 columns e.g.
1 2.5 3.4
1 2.3 3.1
1 2.6 3.9
2 2.9 2.8
2 2.6 2.9
2 2.7 2.9
3 2.3 3.3
3 2.4 3.0
3 2.7 3.2
I thought I could use scan() but don't know how to extend it
2007 Apr 06
1
Orphaned ncvar? (PR#9603)
>
An orphaned package? anyone in Switzerland know if there's an
alternative?
Note the email.
I guess CRAN-R should be notified.
regards, Bob C
> The original message was received at Fri, 6 Apr 2007 16:32:57 -0700
> from vayu.arc.nasa.gov [143.232.122.22]
>
> ----- The following addresses had permanent fatal errors -----
> <juerg.schmidli at env.ethz.ch>
>
2010 Apr 09
3
NAs are not allowed in subscripted assignments
I'm trying to assign NAs to values that satisfy certain conditions (more
complex than shown below) and it gives the right result, but breaks the loop
having done the first one viz:
new<-c(rep(5,4),6)
for (i in 1:6)
{new[new[i]>5.5][i]<-NA}
gives the correct result, though an error message appears which causes a
break if it's in a loop. If I can get rid of the error message and
2006 May 18
1
Function (x) as consecutive values
Hi - I'm trying to avoid using a 'for' loop due to inefficiency and instead use a function (and ultimately tapply as I'm working on a matrix) but I can't figure out how to get 'function' to take the variables as anything other than vectors for example
aa<-0
x<-1:4
test.fun<-function(x)
{aa<-(x*x +aa)
return(aa)}
test.fun(1:4)
This code
2006 Mar 23
2
Default lag.max in ACF
Hi,
The default value for lag.max in ACF implementation is 10*log10(N)
There several publications recommending setting lag.max to:
- N/4 (Box and Jenkins, 1970; Chatfield, 1975; Anderson, 1976;
Pankratz, 1983; Davis, 1986; etc.)
- sqrt(N)+10 (Cryer, 1986)
- 20<=N<=40 (Brockwell and Davis)
Why R uses 10*log10(N) as a default?
Please, give me a reference to a book or article where the
2010 Sep 22
1
Referencing factor name
Simple problem - I want the ylab to automatically pick up x1 rather than
having to define x1 in the plot statement.
x1<-c(1.2,2,3);x2<-c(1,2.1,2.6)
y<-x1
plot(1:3,y, ylab="x1")
There must be a way of accessing the name x1 somehow, but unfortunately I
don't know how to search for it. Any help would be great,
--
View this message in context:
2009 Nov 04
1
Patterned shading in ggplot
Am trying to produce a graph which prints out well in black and white using
ggplot2. I have the following example set up nicely, but want to shade the
red bars in one pattern and the blue in another so they print out clearly.
I tried changing colours to 1 light, 1 dark, but then the overlapping colour
looks virtually identical to the darker one. I noted the option density in
barplot, but
2008 Aug 05
2
Opening R from Tinn without setting directory each time
Hi - I can access R from Tinn-R by going to Options->Main->Application/R and
setting the search path, but each time I exit Tinn-R I have to redefine the
search path. Is there no way of fixing that directory as default? I have
installed R under its default directory C:/Program Files/R/R-2.7.1 and Tinn
under a variety of different places to try to rectify the problem though
currently under
2009 Oct 07
2
Plotting 1 covariate, 3 factors
I'm interested in plotting a y with an x factor as the combination of 2
factors and colour with respect to a third, which the code below does with
interaction.plot(). However, this is because I redefine the x to be 1
factor. Is there a way of getting it to plot without redefining it, and
ideally to not join up the lines BETWEEN levels a and b, but just join those
between after and before for
2008 Jul 15
1
code reduction (if anyone feels like it)
# I am sure that I could be more efficient than this but how? Thanks in
advance.
#GPS in Decimal Degrees in the form longitude latitude
RM215 <- matrix(c(-82.1461363, 33.5959109), nrow=1)
SC <- matrix(c(-82.025888, 33.606454), nrow=1)
RM202 <- matrix(c(-81.9906723, 33.5027653), nrow=1)
RM198 <- matrix(c(-81.926823, 33.4634678), nrow=1)
HC <- matrix(c(-81.920505, 33.46192), nrow=1)
2010 Apr 09
3
"fill in" values between rollapply
Hi,
Sorry ahead of time for not including data with this question.
Using rollapply to calculate mean values for 5 day blocks, I'd use this:
Roll5mean <- rollapply(data, 5, mean, by=5, align = c("left"))
My question is, can someone tell me how to fill in the days between each of
these means with the previously calculated mean? If this doesn't make
sense, I will clarify and
2006 Jun 28
1
Reporting ppr fits and using them externally.
The pursuit projection packages ppr is an excellent contribution to
R. It is great for one-to-three ridge fits,
often somewhat intuitive, and for multi-ridge fits, where it at least
describes a lot of variance.
Like many folk, I need to report the fits obtained from ppr to the
greater, outside, non-R
world. It is fairly obvious how to use the terms alpha and beta to
report on
2008 Sep 21
1
Multiple plots per window
Hi all,
I'm currently working through "The Analysis of Time Series" by Chris
Chatfield. In order to also get a better understanding of R, I play
around with the examples and Exercises (no homework or assignement,
just selfstudy!!).
Exercise 2.1 gives the following dataset (sales figures for 4 week
intervals):
> sales2.1.dataframe
1995 1996 1997 1998
1 153 133 145 111
2
2002 Aug 23
3
y-axis with "break"
Dear R-users
I would like to draw a barplot with a special y-axis. Most of my data points are
in the range from -50 to 50, apart from one value that is 550. I would now like
to have a y-axis from -50 to 50, then a "break" and the "rest" of the y-axis,
let's say from 500 to 600. In order to make clear what I'm trying to do, I
attached a figure.
Is it possible to do
2006 Oct 02
1
CCF and ACF
Dear all,
given two numeric vectors x and y, the ACF(x) at lag k is
cor(x(t),x(t+k)) while the CCF(x,y) at lag k is cor(x(t),y(t-k)). See
below for a simple example.
> set.seed(1)
> x <- rnorm(10)
> y <- rnorm(10)
> x
[1] -0.6264538 0.1836433 -0.8356286 1.5952808 0.3295078 -0.8204684
0.4874291 0.7383247 0.5757814 -0.3053884
> y
[1] 1.51178117 0.38984324
2008 Oct 28
1
acf(): meaning of the blue horizontal lines
Hello,
what are they meaning? It could be something that
would show a threshhold above which the result is
indicating different meanings then just random noise.
But there is no description on the definition of those lines,
so it means nothing, if it is not clearly defined.
Where can I find a detailed definiton?
Ciao,
Oliver
2009 Jun 12
1
Snap axes to origin rather than around it
I'm trying to plot a graph where the axes go through 0,0, rather than around
it combined with a box round the graph, so
x<-0:10;y<-0:10
plot(x,y)
gives me a box but doesn't go through the point 0,0, but stays at a
distance.
In trying to circumvent this problem, I wrote
plot(x,y)
axis(1, pos=c(0,0));axis(2,pos=c(0,0))
which gives me axes that go through the origin, but then I
2009 Aug 10
1
Statistician Needed
Hello,
I've come up with some challenges with my process that are a bit too
complicated for the mailing list.
Is there anyone out there, preferably a real "statistician", who is
willing to consult with me via phone/email for a few hours. I'm happy
to pay you for your time.
Thanks,
-Noah