File:  [Research Unix] / researchv10dc / cmd / matlab / exec / rogers.exec
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 17:21:33 2018 UTC (8 years, 3 months ago) by root
Branches: belllabs, MAIN
CVS tags: researchv10, HEAD
researchv10 Dan Cross

exec('d.boug');			// reads data
<g,k> = size(p);		// p is matrix of gene frequencies
wv = ncen/sum(ncen);		// ncen contains population sizes
pbar = wv*p;			// weighted average of p
p = p - ones(g,1)*pbar; 	// deviations from mean
p = sqrt(diag(wv)) * p; 	// weight rows of p by sqrt of pop size
h = diag(pbar); h = h*(eye-h);	// diagonal contains binomial variance: p*(1-p)
r = p*inv(h)*p'/k;		// normalized covariance matrix
eig(r)'

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.