Resource Image

Marriage Model (with errors)

Author(s): Steven F Railsback

Lang Railsback & Associates

1007 total view(s), 274 download(s)

6 comment(s) (Post a comment)

Summary:
Marriage age model for use with NetLogo and ABM material

Licensed under these terms

Version 1.0 - published on 26 Oct 2018 doi:10.25334/Q4Q721 - cite this

Comments

  1. Danielle Gagne @ on   (Edited: @ on )

    Please can you help me with the errors, I tried to complete the code but still I have an error for the dividing by zero.

    TIA

    Copy link Report abuse

    Your reply
    No attachment

    Your edits
    No attachment

    1. 0 Like

      Drew LaMar @ on

      I might be able to help. Can you attach your nlogo file, either as an edit to your initial comment or as a reply to this one?

      - Drew

      Copy link Report abuse

      Your reply
      No attachment

      Your edits
      No attachment

      1. 0 Like

        Danielle Gagne @ on

        Dear Drew, 

        thank you for your response. I am very new to NetLogo but really want to make this code run as it would be very helpful for my research. I have commented the lines which I am unsure about.. 

        TIA,

        Danielle

        Copy link Report abuse

        Your reply
        No attachment

        Your edits
        MarriageModel-WithErrors-v2.nlogo

        1. 0 Like

          Steven F Railsback @ on

          Danielle, please email me using regular email, not QUBES. If you need to, try using the contact info at:

          http://www.railsback-grimm-abm-book.com/contact-us/

          Steve

          Copy link Report abuse

          Your reply
          No attachment

          Your edits
          No attachment

        2. 0 Like

          Steven F Railsback @ on

          Hi Danielle,

          I have not been following this thread closely but if you are still stuck send me the specifics at: steve.railsback@humboldt.edu

          Steve R.

          Copy link Report abuse

          Your reply
          No attachment

          Your edits
          No attachment

          1. 0 Like

            Danielle Gagne @ on

            Dear Steve,

            thank you for your response. I am unable to get my email through to you, probably due to external email restrictions. I copy my message below:

            thank you very much for reaching out. I am new to NetLogo and wish to study a partnership model with interacting agents, and it would be very helpful to my research to have this model as a first working example.

            I understand that the original code is posted with errors for exercise to the user, but unfortunately I haven't been able to work out all the bugs. In particular, I believe that the initial social network size is sometimes equal to zero, thus leading to an error of dividing by zero when calculating the married fraction.

            Should I add an ifelse statement to the social-network count, so that if it is zero, the marriage fraction is also equal to zero?

            If you could offer me some help in how to fix a solution, I would be ever so grateful.

            TIA and kind regards,

            Danielle G.

            Copy link Report abuse

            Your edits
            No attachment