similar to: Modified Cholesky decomposition for sparse matrices

Displaying 20 results from an estimated 1000 matches similar to: "Modified Cholesky decomposition for sparse matrices"

2007 Apr 24
1
Matrix: how to re-use the symbolic Cholesky factorization?
I have been playing around with sparse matrices in the Matrix package, in particularly with the Cholesky factorization of matrices of class dsCMatrix. And BTW, what a fantastic package. My problem is that I have to carry out repeated Cholesky factorization of a spares symmetric matrices, say Q_1, Q_2, ...,Q_n, where the Q's have the same non-zero pattern. I know in this case one does
2009 Mar 10
5
Cholesky Decomposition in R
Hi everyone: I try to use r to do the Cholesky Decomposition,which is A=LDL',so far I only found how to decomposite A in to LL' by using chol(A),the function Cholesky(A) doesnt work,any one know other command to decomposte A in to LDL' My r code is: library(Matrix) A=matrix(c(1,1,1,1,5,5,1,5,14),nrow=3) > chol(A) [,1] [,2] [,3] [1,] 1 1 1 [2,] 0 2 2
2013 Jun 19
0
Simple example of variables decorrelation using the Cholesky decomposition
Dear all, I made a simple test of the Cholesky decomposition in the package 'Matrix', by considering 2 variables 100% correlated. http://blogs.sas.com/content/iml/2012/02/08/use-the-cholesky-transformation-to-correlate-and-uncorrelate-variables/ The full code is below and can be simply copy&paste in the R prompt. After uncorrelation I still have a correlation of +-100%...
2005 Jan 21
1
Cholesky Decomposition
Can we do Cholesky Decompositon in R for any matrix --------------------------------- [[alternative HTML version deleted]]
2009 Apr 01
2
Need Advice on Matrix Not Positive Semi-Definite with cholesky decomposition
Dear fellow R Users: I am doing a Cholesky decomposition on a correlation matrix and get error message the matrix is not semi-definite. Does anyone know: 1- a work around to this issue? 2- Is there any approach to try and figure out what vector might be co-linear with another in thr Matrix? 3- any way to perturb the data to work around this? Thanks for any suggestions.
2009 Mar 11
0
LDL' Cholesky decomposition
The gchol function in library(kinship) does an LDL decomposition. An updated version has just recently been posted on Rforge, in the bdsmatrix library which is part of survival. > temp <- matrix(c(1,1,1,1,5,8,1,8,14), 3) > gt <- gchol(temp) > as.matrix(gt) # L [,1] [,2] [,3] [1,] 1 0.00 0 [2,] 1 1.00 0 [3,] 1 1.75 1 > diag(gt) # D [1]
2009 Mar 11
0
anyone can help me with Cholesky Decomposition
Hi: what I want to do is decompose the a symmetric matrix A into this form A=LDL' hence TAT'=D,T is inverse of (L)and T is a lower trangular matrix,and D is dignoal matrix for one case A=1 1 1 1 5 5 1 5 14 T=inverse(L)= 1 0 0 -1 1 0 0 -1 1 D=(1,4,9) I tried to use chol(A),but it returns only trangular, anyone know the function can return
2011 Dec 29
1
Cholesky update/downdate
Dear R-devel members, I am looking for a fast Cholesky update/downdate. The matrix A being symmetric positive definite (n, n) and factorized as A = L %*% t(L), the goal is to factor the new matrix A +- C %*% t(C) where C is (n, r). For instance, C is 1-column when adding/removing an observation in a linear regression. Of special interest is the case where A is sparse. Looking at the
2006 Mar 15
1
Log Cholesky parametrization in lme
Dear R-Users I used the nlme library to fit a linear mixed model (lme). The random effect standard errors and correlation reported are based on a Log-Cholesky parametrization. Can anyone tell me how to get the Covariance matrix of the random effects, given the above mentioned parameters based on the Log-Cholesky parametrization?? Thanks in advance Pryseley
2012 Feb 21
1
System is computationally singular error when using cholesky decompostion in MCMC
Hello Everyone I have a MCMC loop to calculate a time varying hierarchical Bayesian structure. This requires me to use around 5-6 matrix inversions in the loop. I use cholesky and chol2inv for the matrix decomposition. Because of the data I am working with I am required to invert a 167 by 167 matrix twice in one iteration. I need to run the iteration for 10000 times, but I get the error
2007 Jan 04
1
Parameter changes and segfault when calling C code through .Call
I am experiencing some odd behavior with the .Call interface, and I am hoping someone out there can help me with it. Below is a simple example (in that there are R packages that do exactly what I want), but this code illustrates the problem. Thanks in advance for any help you can provide. Suppose I want to compute the log density of a multivariate normal distribution using C code and the gsl
2012 Nov 30
1
Choleski decomposition
m <- matrix(nrow=5, ncol=5) m <- ifelse(row(m)==col(m), 1, 0.2) c <- chol(m) # Choleski decomposition u <- matrix(rnorm(2000*5), ncol=5) uc <- u %*% c cr <- pnorm(uc) cr <- qbinom(cr,1,0.5) cor(cr) I expected that the cor(cr) to be 0.2 as i set in m, but the result is around 0.1. Why is that? Thanks -- View this message in context:
2017 Aug 08
1
Nested for loop
Hi Caitlin and Ben, Thanks for your responses! My issue is that I'd like to create one continuous line, rather than 3 lines overlayed. The code I've attached works for a population of 400 and samples 100 times. I'd like to extend this to 300 samples and 3 populations. So, the x-axis would range from 0-300 samples. What I'm having trouble with is finding a way to change the
2006 Dec 12
1
Undefined symbol when trying to dyn.load a shared object
I hope that someone reading this list can offer some suggestions on how I can incorporate external C libraries in C functions that I want to call from R. I have gone through all of the documentation, help files and mailing list archives and have not been able to find a satisfactory solution. I have constructed a simple example of the problem, since my "real" program is much more
2017 Aug 06
0
Nested for loop
Hi Kirsten, I can run your example code but I can't quite follow your division of sampling. Can you restate the the task? Below is what I think you are asking for, but I have the feeling I may be off the mark. Set A: 400 samples, draw 100 in range of 5 to 15 Set B: 800 samples, draw 100 in range of 5 to 15 Set C: 300 samples, draw 100 in range of 5 to 15 Ben > On Aug 5, 2017, at
2017 Aug 05
2
Nested for loop
Hi! Thanks for taking the time to read this. The code below creates a graph that takes 100 samples that are between 5% and 15% of the population (400). What I'd like to do, however, is add two other sections to the graph. It would look something like this: from 1-100 samples take 100 samples that are between 5% and 15% of the population (400). From 101-200 take 100 samples that are between
2017 Aug 06
1
Nested for loop
Hi Ben, That's exactly right! Except for each set it's the sample population that is 400, 800 or 300. I want to take 3 samples, each of 100, where only the population differs. I can do this separately, but I'm having trouble putting them all on the same graph. I'd like to have sample on the x axis (1-300) and estimate on the y axis. I want to show how population affects the
2006 Dec 12
1
include libraries for C code called from R
I hope that someone on this list can help me with this issue. I have searched through all of the documentation and mail archives for a solution, but have been unable to find an answer that addresses my particular problem directly. Suppose I am writing some C code that I want to access from R through the .C function. As part of the C function, I want to include an external C library, such as the
2008 Mar 20
1
Interpretation of Variance decomposition in VAR model
Hi all, This question is not really R related, rather on Statistics subject itself. Even I did not do those using R. however still I want to post it here, because my hope is I could get help from great statisticians who are the very active member of this group. My problem is to interpret Variance decomposition of VAR model in layman's language. Using EViews I got following : Variance
2011 Jul 15
1
Confusing inheritance problem
I have library in development with a function that works when called from the top level, but fails under R CMD check. The paricular line of failure is rsum <- rowSums(kmat>0) where kmat is a dsCMatrix object. I'm currently stumped and looking for some ideas. I've created a stripped down library "ktest" that has only 3 functions: pedigree.R to create a pedigree or