hazim79/behaviorsearch

Shortcut not working for NL 5.0.4, + brainstorms about RNetLogo

Closed this issue · 11 comments

In order to run BehaviorSearch, do I need to go back to NetLogo version 5.03 or 
the version 4.x that BehaviorSearch supports? I ask because I've downloaded 
BehaviorSearch and it does not open.

Original issue reported on code.google.com by benja...@chabot-hanowell.info on 4 Jun 2013 at 1:07

Sorry for the slow response - I was on vacation.  The current version of 
BehaviorSearch (v1.00) should work with NetLogo 5.0.x (including 5.0.4).  
BehaviorSearch needs to be installed into a subfolder of the NetLogo folder 
(usually C:\Program Files\NetLogo 5.0.4\).

Before we can troubleshoot to get more information about why it's not starting 
for you, I'll need to know what OS you're using and how much RAM your system 
has.

Original comment by fsondahl@gmail.com on 10 Jun 2013 at 3:03

Thank you for your reply. Windows 7. 3 GB RAM.

Original comment by benja...@chabot-hanowell.info on 10 Jun 2013 at 3:14

Try going to the "command prompt", and typing everything after the  '>':

> cd "C:\Program Files\Netlogo 5.0.4\BehaviorSearch 1.00"

[Modify the path if necessary for your installation.]

Then run:

> behaviorsearch_gui.bat

Do you get any error messages?

Original comment by fsondahl@gmail.com on 10 Jun 2013 at 4:35

  • Changed state: Started
Thank you. I will try this later today.

Original comment by benja...@chabot-hanowell.info on 10 Jun 2013 at 4:50

I did not get any error messages. I will run from the cmd line from now on.

Another unrelated question/comment:

You know what would be awesome? If there were an RBehaviorSearch package
that I could use in tandem with RNetLogo!


On Mon, Jun 10, 2013 at 9:50 AM, Benjamin Chabot-Hanowell <
benjamin@chabot-hanowell.info> wrote:

Original comment by benja...@chabot-hanowell.info on 10 Jun 2013 at 6:58

Not sure what the issue is, but at least you have a work-around... you could 
make a new shortcut directly to the .bat file if you want.

Re: RNetLogo.  I agree that it might be nice to use these tools together, but 
it's non-trivial to hook them up, since they both use NetLogo's controlling 
API.  My guess is that you'd want to use R to control BehaviorSearch, which in 
turn would control Netlogo. 

As it stands, you *can* use R to explore/visualize the data that BehaviorSearch 
produces.

Original comment by fsondahl@gmail.com on 11 Jun 2013 at 1:43

  • Changed state: Done
Hrm. Let me think about this more deeply. I'm going to do that "aloud" in
this email if that's okay. Just tell me you're business and can't take more
email if you're busy.

I want to link R to NetLogo using RNetLogo because I want to pass a
dataframe from R into NetLogo lists (RNetLogo has a helper function that
does that). The dataframe is basically a set of values simulated from a
statistical model object. Anyway, that's the only reason why I don't just
run the model in BehaviorSearch and analyze the output in R. But if I could
somehow pass data to NetLogo during a BehaviorSearch run, I wouldn't have
to replicate its functionality with R packages. Also, I want to be able to
parallelize the computation because the model will be complex and slow, and
I know how to parallelize in R.

Anyway, thanks for the help with the 5.0.4 problem. I tested out
BehaviorSearch on the Fire model today. It went well!

Original comment by benja...@chabot-hanowell.info on 11 Jun 2013 at 4:11

Is the dataframe the same every time?  If so, you could just convert it into 
NetLogo lists once, and then store those lists directly in the NetLogo source 
code (or store it in a file that's more easily readable directly from NetLogo).

Or when you say "set of of values simulated from a statistical model object", 
does that mean that each time the NetLogo model is run, it's getting different 
data (but drawn from the same statistical distribution)?   Could you 
pre-compute a sufficiently large stockpile of this data and store it in a file, 
which NetLogo would load from each time it runs? Hmm.

Alternatively, could you change your code so that it uses the R-extension 
(where NetLogo is calling R code), instead of the RNetLogo controlling 
software, where R calls NetLogo?  That might work better.  BehaviorSearch 
should work with extensions, although there may be problems running parallel 
threads that both use the R-extension.

Just brainstorming here... hope it helps.

Original comment by fsondahl@gmail.com on 11 Jun 2013 at 5:21

  • Changed title: Shortcut not working for NL 5.0.4, + brainstorms about RNetLogo
Yeah. On second thought I could just have NetLogo read from a file and then
just use NetLogo and BehaviorSeach on their own.
#Benjamin-overthinks-stuff-all-the-time

That is, unless it turns out that I will need to get info from NetLogo into
R to do the statistical modeling (don't think that is the case since it is
basically just input data).

Thank you for the suggestions!

Original comment by benja...@chabot-hanowell.info on 11 Jun 2013 at 5:36

Cool.  Sounds like an interesting project -- send me a copy of your paper 
if/when you write up something?

Original comment by fsondahl@gmail.com on 11 Jun 2013 at 7:35

But of course!

Original comment by benja...@chabot-hanowell.info on 11 Jun 2013 at 7:37