Indeed.
Start here:
http://www.r-bloggers.com/three-tips-for-posting-good-questions-to-r-help-and-stack-overflow/
and then read this:
http://stackoverflow.com/questions/5963269/how-to-make-a-great-r-reproducible-example
Then put some comments into your code about what you think it should do. Oh
I would be biased towards using a heuristic, for instance Threshold
Accepting (TA), for solving such a problem. (TA is implemented in
package NMOF. Disclosure: I am the author of that package.) But you will
not find a ready-to-use solution there.
(1) you need an objective function, ie, a fun
You could try the fPortfolio package.
Wish helps.
jamaj
2008/7/21, fzp2008 <[EMAIL PROTECTED]>:
>
> How to use R to solve the optimisaton problem
>
> Minimize:
> ½*w^T*omega*w+mu^T*w+c^T(w-w0) for w>w0 long position
> ½*w^T*omega*w+mu^T*w-c^T(w-w0) for w
> W: is the update weight of portfolio
>
3 matches
Mail list logo