Sovereign 8s.is mirror of standardgalactic/attribute-norm-evolution
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
2026-04-21 23:08:26 +09:00
flexible_F Initial commit 2026-04-21 22:58:54 +09:00
two_F Initial commit 2026-04-21 22:58:54 +09:00
.gitignore Initial commit 2026-04-21 22:58:54 +09:00
README.md Update README.md 2026-04-21 23:08:26 +09:00
requirements.txt Initial commit 2026-04-21 22:58:54 +09:00

A cultural evolutionary model of attribute-dependent norms on behaviors with and without direct payoffs

This is the source code for

Miyoshi, A., Ihara, Y. A cultural evolutionary model of attribute-dependent norms on behaviors with and without direct payoffs. Sci Rep (2026). https://doi.org/10.1038/s41598-026-49420-3

requirements.txt lists the dependencies for running simulations.

two_F

Analysis with two assessment strategies.

  • config2F.py contains the parameter settings for which simulations are conducted.
  • evolve2F.py contains the function to conduct simulations.
  • PredictedEquilibria_2F.py stores information about equilibria predicted by mathematical analysis, which is used for drawing figures.

two_F/Allgood_Allbad

Cases where F(0) is set to FAllgood and F(1) is set to FAllbad, with error rates of 0.

  • Run Allgood_Allbad.py to conduct simulations.
  • Then, run plot_Allgood_Allbad.py to draw figures.

two_F/Allgood_X0Y1good

Cases where F(0) is set to FAllgood and F(1) is set to FX0Y1good, with error rates of 0.

  • Run Allgood_X0Y1good.py to conduct simulations.
  • Then, run plot_Allgood_X0Y1good.py to draw figures.

two_F/Allgood_Zcommon

Cases where F(0) is set to FAllgood and F(1) is set to FZcommon, with error rates of 0.

  • Run Allgood_Zcommon.py to conduct simulations.
  • Then, run plot_Allgood_Zcommon.py to draw figures.

two_F/effect_of_error

Cases where F(0) is FAllgood and F(1) is FZcommon with non-zero error rates.

  • Run effect_of_error.py to conduct simulations.
  • Then, run plot_effect_of_error.py to draw figures.

flexible_F

Analysis concerning continuously varying assessment strategies.

  • config.py contains the parameter settings for which simulations are conducted.
  • evolve.py contains the function to conduct simulations.

flexible_F/demonstrate

  • Run demonstrate.py to conduct simulations and draw figures displaying each run.
    • At that time, heatF.py is used to draw figures.

flexible_F/from_monomorphic

Simulations with initial states where individuals share the same assessment parameters.

  • Run from_monomorphic.py to conduct simulations.
  • Run discrepancy.py to calculate and save values of Discrepancy.
  • Run discrepancy_plot.py to draw figures and perform permutation tests.

flexible_F/from_uniform

Simulations with initial states where assessment parameters of individuals are drawn from a uniform distribution.

  • Run from_uniform.py to conduct simulations.
  • Run circularvariance_tocsv.py and then circularvariance_graph.py to calculate the resulting values of circular variance and draw a figure.
  • Run mmWNfit.py to fit mixture models to the simulation results.
  • Run scatter_u.py to draw other figures.

flexible_F/from_uniform_envchange

Simulations incorporating a shift of socioeconomic environment.

  • Run from_uniform_envchange.py to conduct simulations.
  • Run plot_ubar.py to draw a figure of average assessment parameters.
  • Run rf_accuracy.py to conduct classifier two-sample tests and visualize the result.
  • Run export_pvalues.py to export p-values in csv file format.