Is there an R function or DLL that calculates a nearest positive semi-definite correlation matrix?
Finding the nearest positive semi-definite matrix is a well-documented common problem in portfolio construction.
NAGS includes a function but the library requires a license.