help with apply, please
On Saturday 19 November 2005 17:24, Gabor Grothendieck wrote:
[...snip...]
Although the above is not wrong I should have removed the rbind
which is no longer needed and simplifying it further, as it seems
that lp will do the rep for you itself for certain arguments, gives:
lp("min", rep(1,3), t(mtrx), ">=", 1)$solution # 1 0 1
Thank you Gabor, this solution is superbe (you never stop amazing me :) Now... it only finds _one_ of the multiple minimum solutions. In the toy example, there are two minimum solutions, hence I reckon the output should have been a list with: [[1]] [1] 1 0 1 [[2]] [1] 0 1 1 Also, thanks to Duncan and yes, I do very much care finding the smallest possible solutions (if I correctly understand your question). It seems that lp function is very promising, but can I use it to find _all_ minimum solutions? Adrian
Adrian DUSA
Arhiva Romana de Date Sociale
Bd. Schitu Magureanu nr.1
050025 Bucuresti sectorul 5
Romania
Tel./Fax: +40 21 3126618 \
+40 21 3120210 / int.101