Displaying 1 result from an estimated 1 matches for "cells0".
Did you mean:
cells
2011 Dec 12
0
Rsolnp package: warning messages
...tion(x){
all3=sum(mat%*%x)
p_b=mat[1:BR,]%*%x/all3
return(as.vector(p_b))
}
#the lower limit for inequalities
ineqLB=rep(0.00001,BR)
#the upper limit for the inequalities
ineqUB=rep(1.00001,BR)
# the lower and upper bounds for the variables
LB=rep(0,CELL)
UB=rep(1,CELL)
#the seed for variables
cells0=rep(.3,9)
#solving the problem
sol=solnp(cells0,fun=obj,eqfun=equal1,eqB=eqB,ineqfun
=inequal1,ineqLB=ineqLB,ineqUB=ineqUB,LB=LB,UB=UB,control=list(outer.iter=400))
cells=sol$pars
cells
equal1(cells)