Rank: 414 based on 168 downloads (last 30 days) and 6 files submitted
photo

Calvin Price

E-mail

Personal Profile:
Professional Interests:

 

Watch this Author's files

 

Files Posted by Calvin View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
25 Feb 2011 Screenshot Autocorrelation Function (ACF) Computes ACF for a given series and plots correlogram. Author: Calvin Price statistics 112 5
  • 4.88889
4.9 | 9 ratings
28 Jan 2010 Generate multivariate normal data Generate sample data based on user defined correlations (not covariances). Author: Calvin Price statistics 4 0
03 Nov 2009 Full Rank Factorization Performs a full rank factorization, X=KL Author: Calvin Price linear algebra, full rank factorizati..., full rank decompositi..., mathematics 5 1
  • 3.0
3.0 | 2 ratings
26 Dec 2008 Screenshot Plot a plane or line in 3D User specifies two independent vectors, and the corresponding plane is graphed. Author: Calvin Price plane, 3d, plot, subspace 21 0
  • 2.0
2.0 | 1 rating
28 Jul 2008 Create orthonormal vectors Creates a random set of orthonormal vectors Author: Calvin Price linear algebra, orthonormal vectors, orthogonal vectors, independent vectors 3 0
Comments and Ratings on Calvin's Files View all
Updated File Comment by Comments Rating
30 May 2013 Autocorrelation Function (ACF) Computes ACF for a given series and plots correlogram. Author: Calvin Price Fatima

The code solved my problem after got confused with several other codes although I m so biginner and I had to be paitint to get it.
Thank you

27 Apr 2013 Autocorrelation Function (ACF) Computes ACF for a given series and plots correlogram. Author: Calvin Price Martin

18 Jan 2013 Autocorrelation Function (ACF) Computes ACF for a given series and plots correlogram. Author: Calvin Price BIYIKLI, H.Muhammed

06 Jun 2012 Sort Eigenvectors & Eigenvalues Sort a set of eigenvectors and corresponding eigenvalues Author: Calvin Price Hahn, Liz

08 May 2012 Autocorrelation Function (ACF) Computes ACF for a given series and plots correlogram. Author: Calvin Price Dmitry

Hey Calvin, ACFs produced by your code are biased towards zero...

The reason for that is that the first k elements in cross_sum (variable of the sub-function) are always zero. Also, dimensions of cross_sum after the loop in lines 104-106 are always Nx1. In large sample the bias is small but in small samples it might be sensible.

Given that matlab is very bad at handling loops it is better to avoid them altogether if possible. I adjusted your code by removing the sub-function completely, "global" attributes for N and ybar (lines 46 and 48) and substituting loop in lines 52-54 by

for i = 1:p
cross_sum=(y(i+1:N)-ybar)'*(y(1:N-i)-ybar);
yvar = (y-ybar)'*(y-ybar) ;
ta(i) = (cross_sum / yvar)*(N/(N-i)) ;
end

Hope that helps everyone

Top Tags Applied by Calvin
linear algebra, mathematics, statistics, 3d, eigenvalues
Files Tagged by Calvin View all
Updated   File Tags Downloads
(last 30 days)
Comments Rating
25 Feb 2011 Screenshot Autocorrelation Function (ACF) Computes ACF for a given series and plots correlogram. Author: Calvin Price statistics 112 5
  • 4.88889
4.9 | 9 ratings
28 Jan 2010 Generate multivariate normal data Generate sample data based on user defined correlations (not covariances). Author: Calvin Price statistics 4 0
03 Nov 2009 Full Rank Factorization Performs a full rank factorization, X=KL Author: Calvin Price linear algebra, full rank factorizati..., full rank decompositi..., mathematics 5 1
  • 3.0
3.0 | 2 ratings
26 Dec 2008 Screenshot Plot a plane or line in 3D User specifies two independent vectors, and the corresponding plane is graphed. Author: Calvin Price plane, 3d, plot, subspace 21 0
  • 2.0
2.0 | 1 rating
28 Jul 2008 Create orthonormal vectors Creates a random set of orthonormal vectors Author: Calvin Price linear algebra, orthonormal vectors, orthogonal vectors, independent vectors 3 0

Contact us