[R] Problem with allp ossible combination.

2006-07-31 Thread Arun Kumar Saha
Dear R Users, Suppose I have a dataset like this: a b 39700 485.00 39300 485.00 39100 480.00 38800 487.00 38800 492.00 39300 507.00 39500 493.00 39400 494.00 39500 494.00 39100 494.00 39200 490.00 Now I want get a-b for all possible combinations of a and b. Using

[R] Geometrical Interpretation of Eigen value and Eigen vector

2006-08-10 Thread Arun Kumar Saha
Dear all, It is not a R related problem rather than statistical/mathematical. However I am posting this query hoping that anyone can help me on this matter. My problem is to get the Geometrical Interpretation of Eigen value and Eigen vector of any square matrix. Can anyone give me a light on it?

[R] Adding Grid lines

2006-08-22 Thread Arun Kumar Saha
Dear all R users, Can anyone please tell me how to add grid lines in any plot in R including in Histogram, QQ plot etc? Thanks and regards, Arun [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list

[R] Waring message in mvBEKK.est

2006-08-24 Thread Arun Kumar Saha
Deal all R users, I am getting a warning message negative inverted hessian matrix element in: mvBEKK.est(weekly.return.all, order = c(2, 1)) while I am using mvBEKK.estlibrary to estimate time varying Covariance matrix using Bivariate Garch. Can anyone please tell me in details why I am getting

[R] Adding a footnote in plot-window in R

2006-08-26 Thread Arun Kumar Saha
Dear all R users, Suppose, x = rnorm(1000) y = rt(1000,3) plot(range(1:1000),range(x,y),type=n,xlab=NA,ylab=NA) lines(x,col=red) lines(y,col=blue) Now I want to put a footnote in the plot window to tell that RED lines represents the random numbers from normal-dist and blue line represents

[R] How to change the color of Plot area.

2006-08-28 Thread Arun Kumar Saha
Dear all R users, Is there any effective way to change the body color of any plot? I am aware of the function par(bg=black), but the problem with this is, it change the color of entire graphics window. But I want to see that only plot area will have color for example RED and rest of the area

[R] Need help to estimate the Coef matrices in mAr

2006-08-29 Thread Arun Kumar Saha
Dear R users, I am using mAr package to fit a Vector autoregressive model to my data. But here I want to put some predetermined values for some elements in coefficient matrix that mAr.est going to estimate. For example if p=3 then I want to put A3[1,3] = 0 and keep rest of the elements of

Re: [R] Need help to estimate the Coef matrices in mAr

2006-09-20 Thread Arun Kumar Saha
that off the top if my head. Hope this helps. Spencer Graves Arun Kumar Saha wrote: Dear R users, I am using mAr package to fit a Vector autoregressive model to my data. But here I want to put some predetermined values for some elements in coefficient matrix that mAr.est

[R] Problem with data frame

2006-04-24 Thread Arun Kumar Saha
Dear r-users, suppose I have n normal distributions with parameter N(0,i) i=1,2,...,n respectively. Now I want to generate 500 random number for each distribution. And want to put all 500*n random numbers in a single data frame. I tried with following code: n=20 random = data.frame(n) for

[R] Correlation matrix

2006-05-03 Thread Arun Kumar Saha
Dear R users, Suppose I have a 4*5 data frame like this: Date x1 x2 x3 x4 1/1/2004100 22 12 34 2/1/200433-22 33 12 3/1/20041212 -115 4/1/20041 223 22 1 Now I want to get a correlation matrix

[R] Please help me to combine two datasets.

2006-05-11 Thread Arun Kumar Saha
Dear r-users, Suppose I have two data sets data set-1 Date height 1/11/2005 10 2/11/2005 23 3/11/2005 54 4/11/2005 21 5/11/2005 22 data set-2 weight 32 45 11 Now I want to combine this two data sets. i.e. i want to see: Date

[R] Combinig two data frames

2006-06-12 Thread Arun Kumar Saha
Dear all r-users, Suppose I have two data frame: A 1 3 4 5 2 and B 5 6 3 5 Now I want combine this two data frames without losing any value from either data frame. More precisely I want to see AB 1 5 3 6 4 3 5 5 2 NA I tried with cbind function but failed, as it only works

[R] NA values

2006-06-12 Thread Arun Kumar Saha
Dear all R users, I am wondering whether there is any way to replace all NA values in a data frame by some numerical value, suppose 1000? Thanks and Regards [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list

[R] Garch Warning

2006-06-13 Thread Arun Kumar Saha
Dear all R-users, I wanted to fit a Garch(1,1) model to a dataset by: garch1 = garch(na.omit(dat)) But I got a warning message while executing, which is: Warning message: NaNs produced in: sqrt(pred$e) The garch parameters that I got are: garch1 Call: garch(x = na.omit(dat))

Re: [R] Garch Warning

2006-06-14 Thread Arun Kumar Saha
this listserve, please submit a simple, self-contained / reproducible example, as suggested the posting guide! www.R-project.org/posting-guide.html. hope this helps. spencer graves Arun Kumar Saha wrote: Dear all R-users, I wanted to fit a Garch(1,1) model to a dataset

[R] Problem on Matrix multiplication

2006-06-15 Thread Arun Kumar Saha
Dear all r-users, I am getting a big problem with matrix multiplication suppose I have, weight Weight 1 1067640 2 8871500 3 42948778 4 127583735 5 2200 6 4400 7 5685 8 23805662 and, s a b c d

[R] Garch warning

2006-06-16 Thread Arun Kumar Saha
Dear all R-users, Previously I posted the same query in R-Help. But I haven't got the solution. So I am posting the same query again. It is my strong hope that I will get my solution this time. I wanted to fit a Garch(1,1) model to the following data set by: garch1 = garch(dat) But I got a

[R] GARCH

2006-06-20 Thread Arun Kumar Saha
Dear all R-users, I have a GARCH related query. Suppose I fit a GARCH(1,1) model on a dataframe dat garch1 = garch(dat) summary(garch1) Call: garch(x = dat) Model: GARCH(1,1) Residuals: Min 1Q Median 3Q Max -4.7278 -0.3240 0. 0.3107 12.3981 Coefficient(s):

[R] how I can perform Multivariate Garch analysis in R

2006-02-13 Thread Arun Kumar Saha
Dear aDVISOR, Hope I am not disturbing you. Can you tell me how I can perform Multivariate Garch analysis in R. Also please, it is my humble request let me know some resource materials on Multivariate Garch analysis itself. Sincerely yours, -- Arun Kumar Saha, M.Sc.[C.U.] S T A T I S T I C I

[R] Maximum Likelihood Estimation

2006-03-01 Thread Arun Kumar Saha
hi all, Can anyone tell me how to do Maximum Likelihood Estimation in R? Thanks in advance Arun -- [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the

[R] mle.

2006-03-01 Thread Arun Kumar Saha
hi all, suppose I have: r[i] ~ N(0, h[i]) h[i] = a + b*r[i-1] + c*h[i-1] for all i=2..n I want to get estimates of a, b, c by mle. Can you tell me how to do that? thanks in advance, Arun [[alternative HTML version deleted]] __

[R] Calculation of Eigen values.

2006-10-18 Thread Arun Kumar Saha
Dear all R users, Can anyone tell me to calculate Eigen value of any real symmetric matrix which algorithm R uses? Is it Jacobi method ? If not is it possible to get explicit algorithm for calculating it? Thanks and regards, Arun [[alternative HTML version deleted]]

[R] Hessian matrix

2006-10-31 Thread Arun Kumar Saha
Dear all R users, Is there any way to calculate hessian matrix of a given function at any given point? Regards [[alternative HTML version deleted]] __ R-help@stat.math.ethz.ch mailing list https://stat.ethz.ch/mailman/listinfo/r-help PLEASE

[R] fmincon equivalent in R

2006-12-08 Thread Arun Kumar Saha
Dear all R users, I am wondering if there are any function for Constraint optimization in R. Especially i am looking for a R - equivalent of fmincon function in MATLAB. Thanks and regards, Arun [[alternative HTML version deleted]] __

[R] Constraint Optimization problem.

2006-12-08 Thread Arun Kumar Saha
Dear all R users, I have a optimization problem like this: f(x,y) is a function with two variables, x, and y. Variable x is unbounded but y lies between [-10, 10]. I want to minimize f(x,y) subject to a constraint x + y 5. Can anyone tell me which R function should I use. I already gone

[R] Time series plot

2007-01-03 Thread Arun Kumar Saha
Dear all R users, Suppose I have a data set like this: date price 1-Jan-02 4.8803747 2-Jan-02 4.8798430 3-Jan-02 4.8840133 4-Jan-02 4.8803747 5-Jan-02 4.8749683 6-Jan-02 4.8754263 7-Jan-02 4.8746628 8-Jan-02 4.8753500 9-Jan-02 4.8882416 10-Jan-02

[R] 3D Plot

2007-01-17 Thread Arun Kumar Saha
Hi all R users, I want to draw a 3D plot, where the Z-axis will represent the normal densities each with zero mean but different volatilities, Y-axis will represent the SD [volatilities), and X-axis will represent time at which these SD are calculated. Can anyone give me any clue? Your help will

[R] Insert R logo

2007-01-20 Thread Arun Kumar Saha
Dear all R users, I want to insert the R logo in every graphic that I made in my Statistical analysis using R. Can anyone tell me whether is it possible or not and if possible how to do this? your help will be highly appreciated. Thanks and Regards, Arun [[alternative HTML version

[R] Finding the effect of Box-Cox transformation using vis.boxcoxu

2007-01-21 Thread Arun Kumar Saha
Dear all R users, I have a dataset 'data' and I want to see the effect of Box-Cox transformation on it Interactively for different lambda values. I already got a look on function vis.boxcoxu in package TeachingDemos. But I didn't find any option to put user's own dataset. Can anyone tell me how

[R] Combining two datasets

2007-01-31 Thread Arun Kumar Saha
Dear all R users, Suppose I have two data sets: data1: 1,3,5,7,9 data2: 2,4,6,8 Now I want to combine these two data sets like that: data = 1,2,3,4,5,6,7,8,9 Can anyone tell me how to do that? Thanks and regards, [[alternative HTML version deleted]]

[R] Cumulant

2007-02-17 Thread Arun Kumar Saha
Dear all R users, Is there any function to calculate sample cumulant in R for any order? I did make a search using RSiteSearch but got only cum3 function. Your help will be highly appreciated. Thanks [[alternative HTML version deleted]] __

[R] Drawing Tangent

2007-04-26 Thread Arun Kumar Saha
Dear all R-users, I would like to draw a tangent of a given function for a particular (given) point. However the straight line representing it should not cut any axis, it should be a small line. Can anyone tell me how to do this? Thanks, Arun [[alternative HTML version deleted]]

[R] Problem while working with SPSS data

2007-05-26 Thread Arun Kumar Saha
Dear all R users, I got a strange problem while working with SPSS data : I wrote following : library(foreign) data.original = as.data.frame(read.spss(file=c:/Program Files/SPSS/Employee data.sav)) data = as.data.frame(cbind(data.original$MINORITY, data.original$EDUC, data.original$PREVEXP,

[R] Regarding Bivariate normal distribution.

2007-07-25 Thread Arun Kumar Saha
Dear all R gurus, My question is related to statistics rather directly to R. Suppose (X,Y) has a bivariate normal distrubution. I want to find two values of X and Y say x, and y respectively, such that: P[Xx, Yy] = 0.05 My questions are : 1. Can x and y be uniquely found? 2. If it is, how I

[R] Est of SE of coefficients from lm() function

2007-08-24 Thread Arun Kumar Saha
Dear all R users, Can anyone tell me how I can get estimate of SE of coefficients from, lm() function? I tried following : x = 1:10 lm(x[-1]~x[-10]-1)$coefficients Here I got the est. of coefficient, however I also want to get some automated way to get estimate of SE. Regards,