我想要通过R 构造投资组合的有效边界,在看到这篇文章(https://cosx.org/2013/08/use-r-to-do-portfolio-optimization)实践之后却发现,当我将股票支数提高到220支左右时,这个函数就失效了,不知道是自己的问题还是函数本身的限制。
当我使用220支股票时,提示
Error in colnames<-(*tmp*, value = names(getMu(Data))) :
attempt to set 'colnames' on an object with less than two dimensions
有没有哪位高手能帮我解答一下......或者是否可以用其他函数代替