Displaying 20 results from an estimated 6000 matches similar to: "moving correlation coef ?"
1997 May 11
2
R-alpha: Logarithmic scales
Here are another three problems with logarithmic scales:
1) segments() does not work with logarithmic scales. I suggest to change
lines 962-973 in "plot.c":
for (i = 0; i < n; i++) {
if (FINITE(xt(x0[i%nx0])) && FINITE(yt(y0[i%ny0]))
&& FINITE(xt(x1[i%nx1])) && FINITE(yt(y1[i%ny1]))) {
GP->col = INTEGER(col)[i % ncol];
2008 Aug 28
4
Help with shading a polygon below a segment of a curve (normal distribution)
Dear R users,
I still feel new to R so please apologize if I am doing something stupid
here. My use of the polygon() function produces a result that I cannot
comprehend: In a plot, I would like to shade the area below a normal
distribution. However, I do not want the entire area to be shaded, but
just the area on the right side of a vertical line that I draw through
the distribution (in
2008 Jun 20
2
Problems with basic loop
I'm having trouble creating a looping variable and i can't see wher ethe
problem arises from any hep gratfully appreciated
First create a table
x<-table(SURVEY$n_0,exposed)
> x
exposed
False True
Under 16 24 1
16-19 68 9
20-24 190 37
25-34 555 204
35-44 330 87
45-54 198 65
55-64 67 35
65+
2010 Dec 08
2
VARMA
Hi all,
I want to estimate parameters from a VARMA(p,q)-Modell.
The equations of the model or the model structures is given by:
Xt=beta1+beta2*Xt-1+beta3*Yt-1+epsilon1
Yt=beta4+beta5*Yt-1+espilon2
epsilon1 and espilon2 are white noise.
Xt is given by a vector of n elements e.g. (2, 4, 7, 9, …,n)’ and Yt is
given by a vector of n elements e.g. (4,9,12,17,…,n)’.
The lineVar from
2001 Feb 15
1
cointegrating regression
Hi all,
Can I run a cointegrating regression, for example
delta Xt=a1(Yt-1-cXt-1)+E1t
and
delta Yt=-b1(Yt-1-cXt-1)+E2t
with R were
Xt and Yt are non stationary time series at t
a,b,c are parameters and E1t and E2t are error terms at t.
Yt-Xt is stationary
Any suggestions are welcome.
Best regards,
/fb
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-help mailing
2001 Aug 27
1
colorbar legend for image()
Hi,
are there any plans to add a colorbar legend to image()?
Or such a possibility already implemented which I just haven't
discovered yet. Anyway, I will be willing to spent some time on the
implementation if there isn't anyone working on that already.
Thanks
Thomas
-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-.-
r-devel mailing list -- Read
2005 Nov 09
2
problem with Running Locfit
Dear R users,
i am using locfit package developed by loader in R software, my problem is that as i am doing independont forecast using locfit object , i am able to do independont forecast for more than one years simultaniously. But when i am doing one year forecast(single) this code is giving following error...
"Warning message:
'newdata' had 1 rows but variable(s) found have 24
2006 Jul 07
2
Multistage Sampling
Dear WizaRds, dear Thomas,
First of all, I want to tell you how grateful I am for all your
support. I wish I will be able to help others along one day the same way
you do. Thank you so much. I am struggling with a multistage sampling
design:
library(survey)
multi3 <- data.frame(cluster=c(1,1,1,1 ,2,2,2, 3,3), id=c(1,2,3,4,
1,2,3, 1,2),
nl=c(4,4,4,4, 3,3,3, 2,2), Nl=c(100,100,100,100,
2012 Jun 01
1
trouble with append() in a for loop
Hello all,
*
*
I'm having some difficulty, and I think the problem is with how I'm using
append() nested inside a for loop. The data are:
y,x
237537.61,873
5007.148438,227
17705.77306,400
12396.64369,427
228703.4021,1173
350181.9752,1538
59967.79376,630
140322.7774,710
42650.07251,630
5382.858702,264
34405.82429,637
92261.34614,980
144927.1713,1094
362998.7355,1420
203313.6442,1070
2005 Mar 05
4
How to use "lag"?
Is it possible to fit a lagged regression, "y[t]=b0+b1*x[t-1]+e",
using the function "lag"? If so, how? If not, of what use is the
function "lag"? I get the same answer from y~x as y~lag(x), whether
using lm or arima. I found it using y~c(NA, x[-length(x)])). Consider
the following:
> set.seed(1)
> x <- rep(c(rep(0, 4), 9), len=9)
> y <-
2006 Nov 07
1
Re : Draw a circle with a given radius in an existing map
Un texte encapsul? et encod? dans un jeu de caract?res inconnu a ?t? nettoy?...
Nom : non disponible
Url : https://stat.ethz.ch/pipermail/r-help/attachments/20061107/01cea378/attachment.pl
2002 Mar 21
1
legend - bug with argument angle (PR#1404)
When legend() is used with the angle argument as follows, not only the
boxes beside the legend text, but also the whole legend box is filled
with shading lines.
I think this is not intended:
plot(1:10)
legend(8, 4, c("A", "B"), angle=c(10, 80), fill=NULL, density=20)
I'd suggest as a fix (legend.R of R-1.5.0):
25c25
< rect2 <- function(left, top, dx, dy,
2005 Oct 15
2
regression using a lagged dependent variable as explanatory variable
Hi,
I would like to regress y (dependent variable) on x (independent variable) and y(-1).
I have create the y(-1) variable in this way: ly<-lag(y, -1)
Now if I do the following regression lm (y ~ x + ly) the results I obtain are not correct.
Can someone tell me the code to use in R in order to perform a regression using as explanatory variable a lagged dependent variable?
My best regards,
2017 May 31
4
stats::line() does not produce correct Tukey line when n mod 6 is 2 or 3
Seriously, if a method gives a wrong result, it's wrong. line() does NOT
implement the algorithm of Tukey, even not after the patch. We're not
discussing Excel here, are we?
The method of Tukey is rather clear, and it is NOT using the default
quantile definition from the quantile function. Actually, it doesn't even
use quantiles to define the groups. It just says that the groups
2009 Aug 27
1
Wishlist: specify the border color of boxes in legend() (PR#13913)
I could not find a way to specify the border color of the boxes drawn in
a legend, so that the legend can match exactly the colors of the actual
plot (e.g. in the case of two superimposed histograms which have
different shading and different borders).
Indeed, the legend function seems to hard code the color "black" for the
borders in this call:
rect2(left = xt, top = yt +
2008 Jul 27
1
Color of box frame in Legend (Was: Matrix barplot)
On Sun, 27 Jul 2008, S Ellison wrote:
> Looking at the legend() source the filled box line colour is hardcoded :
> if (mfill) {
> if (plot) {
> fill <- rep(fill, length.out = n.leg)
> rect2(left = xt, top = yt + ybox/2, dx = xbox, dy = ybox,
> col = fill, density = density, angle = angle,
> border =
2003 Feb 24
2
"trace" argument in legend() (PR#2578)
Full_Name: Jerome Asselin
Version: 1.6.2
OS: RedHat Linux 7.2
Submission from: (NULL) (142.103.173.179)
Should be an easy fix...
Consider the examble below:
plot(0,0)
legend(0,0,c("Hello!","Hi!"),pch=1:2,lty=1:2,trace=T)
It gives the following trace:
> plot(0,0)
> legend(0,0,c("Hello!","Hi!"),pch=1:2,lty=1:2,trace=T)
xchar= 0.05178 ;
2004 Nov 08
1
whishlist: legend - changing color of the boxes-border
Hi,
Drawing a legend I would like to be able to specify the color of boxes which are drawn if fill or density is specified.
eg.
legend(0,40000,c("raw","LR/PR-TPS"),fill=c(1,2),col=c(1,2),density=c(20,20),angle=c(-20,45),bty="n")
Currently the color of the boxes -- border is always black and can *not* be changed. To get this option only a *minimal* change is
2011 Aug 15
3
Help on how to use predict
Dear R-Users
My problem is quite simple: I need to use a fitted model to predict the next
point (that is, just one single point in a curve).
The data was divided in two parts: identification (x and y - class matrix)
and validation (xt and yt - class matrix). I don't use all values in x and
y but only the 10 nearest points (x[b,] and y[b,]) for each regression (b is
a vector with the
2013 Apr 01
1
Parameter Estimation in R with Sums and Lagged Variables
Hi guys,
I am afraid I am stuck with an estimation problem.
I have two variables, X and Y. Y is explained by the weighted sum of n
lagged values of X. My aim is to estimate the two parameters
c(alpha0,alpha1) in:
Yt = Sum from j=1 to n of ( ( alpha0 + alpha1 * j ) * Xt-j )
Where Xt-j denotes the jth lag of X.
I came up with this approach because I thought it would be a good idea to
estimate