On Thu, Sep 22, 2011 at 06:46:23PM +0000, Joseph Boyer wrote:
> Would someone be so kind as to provide example code where they use the 
> suggestions argument in  the rgba function
> In genalg? I can't get it to work.
> 
> The following code works just fine:
> 
> GenFit <-rbga(Lower, Upper, evalFunc = evaluate)
> 
> Lower and Upper are each numeric vectors with 7 elements. Evaluate is an 
> objective function.
> However, when I want to use a suggested chromosome, I get an error message. 
> My code is
> 
> start <- c(1,0.1,10, 100,1,100,1)
> 
> suggestions <- list(start)
> 
> GenFit <-rbga(Lower, Upper, suggestions = suggestions, evalFunc = evaluate)
> 
> The error message is:
> 
> Error in 1:suggestionCount : argument of length 0
> 
> Thanks.

rbga( c( -1, -1), c( 1, 1), evalFunc= function( string){ sum(
string**2)**0.5}, suggestions=t( as.data.frame( c( 0, 0))))

Regards

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to