e.g. the original GL is used for the first population while the bootstrapped GL is used for the second population. Thus the likelihood calculation is currently wrong, within bootstrap iterations of realSFS for 2d spectra (other dimensions are fine, as is the non-bootstrap SFS estimate). This may be responsible for the wacky spectra in issues #100 and #130.
There is a coding error in the bootstrapping of the 2d-SFS, within the function
emStep2
(realSFS_optim.cpp line 211) ... whereinner[inc] = pre[inc]*gls[0]->mat[s][x]*gls[1]->mat[bootstrap[s]][y];
should instead be
inner[inc] = pre[inc]*gls[0]->mat[bootstrap[s]][x]*gls[1]->mat[bootstrap[s]][y];
e.g. the original GL is used for the first population while the bootstrapped GL is used for the second population. Thus the likelihood calculation is currently wrong, within bootstrap iterations of realSFS for 2d spectra (other dimensions are fine, as is the non-bootstrap SFS estimate). This may be responsible for the wacky spectra in issues #100 and #130.
Nate