{"id":15555175,"url":"https://github.com/psolymos/bsims","last_synced_at":"2025-10-07T02:17:01.060Z","repository":{"id":53078100,"uuid":"186942180","full_name":"psolymos/bSims","owner":"psolymos","description":"Bird Point Count Simulator","archived":false,"fork":false,"pushed_at":"2025-09-06T07:17:21.000Z","size":142511,"stargazers_count":4,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-06T02:00:52.781Z","etag":null,"topics":["bias","birds","detectability","shiny","simulation","survey-design"],"latest_commit_sha":null,"homepage":"https://peter.solymos.org/bSims/","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/psolymos.png","metadata":{"files":{"readme":"README.Rmd","changelog":"NEWS.md","contributing":null,"funding":null,"license":null,"code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-16T03:12:02.000Z","updated_at":"2025-09-06T07:12:24.000Z","dependencies_parsed_at":"2024-10-02T15:07:13.219Z","dependency_job_id":"a62328e0-05f8-4f6a-b565-d34c76bee9b3","html_url":"https://github.com/psolymos/bSims","commit_stats":{"total_commits":316,"total_committers":2,"mean_commits":158.0,"dds":"0.012658227848101222","last_synced_commit":"97d4472d9a158af3a95b6eef38e75108e76645b9"},"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/psolymos/bSims","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/psolymos%2FbSims","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/psolymos%2FbSims/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/psolymos%2FbSims/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/psolymos%2FbSims/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/psolymos","download_url":"https://codeload.github.com/psolymos/bSims/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/psolymos%2FbSims/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278708004,"owners_count":26031932,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-07T02:00:06.786Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["bias","birds","detectability","shiny","simulation","survey-design"],"created_at":"2024-10-02T15:07:06.868Z","updated_at":"2025-10-07T02:16:56.040Z","avatar_url":"https://github.com/psolymos.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput:\n  md_document:\n    variant: gfm\n---\n\n```{r, echo = FALSE}\nknitr::opts_chunk$set(\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"README-\"\n)\nset.seed(0)\n```\n\n# bSims: Bird Point Count Simulator\n\n\u003cimg src=\"https://raw.githubusercontent.com/psolymos/bSims/master/bsims.gif\" align=\"right\" style=\"padding-left:10px;background-color:white;\" /\u003e\n\nA highly scientific and utterly addictive bird point count simulator to test statistical assumptions and to aid survey design.\n\n[![CRAN version](https://www.r-pkg.org/badges/version/bSims)](https://CRAN.R-project.org/package=bSims)\n[![CRAN RStudio mirror downloads](https://cranlogs.r-pkg.org/badges/grand-total/bSims)](https://peter.solymos.org/bSims/)\n[![check](https://github.com/psolymos/bSims/actions/workflows/check.yml/badge.svg)](https://github.com/psolymos/bSims/actions/workflows/check.yml)\n\n\u003e _\"I've yet to see any problem, however complicated, which when you looked at it the right way didn't become still more complicated.\"_\n\u003e -- Poul Anderson, Call Me Joe \n\n\u003e *“Love the simulation we're dreaming in”* - Dua Lipa, Physical\n\nThe goal of the package is to:\n\n- test statistical assumptions,\n- aid survey design,\n- and have fun while doing it!\n\nDesign objectives:\n\n- small (point count) scale implementation,\n- habitat is considered homogeneous except for edge effects,\n- realistic but efficient implementation of biological mechanisms and observation process,\n- defaults chosen to reflect common practice and assumptions,\n- extensible (PRs are welcome).\n\nSee the package in action in the [**QPAD\nBook**](https://peter.solymos.org/qpad-book/).\n\nCheck out the [**QPAD workshop**](https://peter.solymos.org/qpad-workshop/).\n\nRead/cite the paper [**Agent-based simulations improve abundance estimation**](https://rdcu.be/doDwI) (DOI 10.1007/s42977-023-00183-2).\n\n## Install\n\nCRAN version:\n\n```{r eval=FALSE}\ninstall.packages(\"bSims\")\n```\n\nDevelopment version:\n\n```{r eval=FALSE}\nremotes::install_github(\"psolymos/bSims\")\n```\n\nSee what is new in the [NEWS](NEWS.md) file.\n\n## License\n\n[GPL-2](https://www.gnu.org/licenses/old-licenses/gpl-2.0.html)\n\nPlease cite (see `citation(\"bSims\")`) the paper:\n\nSolymos, P. 2023. Agent-based simulations improve abundance estimation. _Biologia Futura_ 74, 377--392 [DOI 10.1007/s42977-023-00183-2](https://doi.org/10.1007/s42977-023-00183-2), [link to PDF](https://rdcu.be/doDwI).\n\n## Contributing\n\nFeedback and contributions are welcome:\n\n- submit feature request or report issues [here](https://github.com/psolymos/bSims/issues),\n- fork the project and submit pull request, see [CoC](CODE_OF_CONDUCT.md).\n\n## Examples\n\n### Command line\n\n```{r message=FALSE,warning=FALSE}\nlibrary(bSims)\n\nphi \u003c- 0.5\ntau \u003c- 1:3\ndur \u003c- 10\nrbr \u003c- c(0.5, 1, 1.5, Inf)\ntbr \u003c- c(3, 5, 10)\n\nl \u003c- bsims_init(10, 0.5, 1)\np \u003c- bsims_populate(l, 1)\na \u003c- bsims_animate(p, vocal_rate=phi, duration=dur)\no \u003c- bsims_detect(a, tau=tau)\n\nx \u003c- bsims_transcribe(o, tint=tbr, rint=rbr)\n\nget_table(x)\n\nhead(get_events(a))\n\nhead(get_detections(o))\n```\n\n### Shiny apps\n\nA few [Shiny](https://shiny.posit.co/) apps come with the package.\nThese can be used to interactively explore the effects of different settings.\n\nCompare distance functions:\n\n```{r eval=FALSE}\nrun_app(\"distfunH\")\nrun_app(\"distfunHER\")\n```\n\nCompare simulation settings for single landscape:\n\n```{r eval=FALSE}\nrun_app(\"bsimsH\")\nrun_app(\"bsimsHER\")\n```\n\n### Replicating simulations\n\nInteractive sessions can be used to explore different settings.\nSettings can be copied from the Shiny apps and replicated using the\n`bsims_all` function: \n\n```{r}\nb \u003c- bsims_all(extent=5, road=1, density=c(1,1,0))\nb\n```\n\nThe object has handy methods:\n\n```{r eval=FALSE}\nb$settings()      # retrieve settings\nb$new()           # replicate once\nb$replicate(10)   # replicate 10x\n```\n\nThe `$replicate()` function also runs on multiple cores:\n\n```{r}\nlibrary(parallel)\nb \u003c- bsims_all(density=0.5)\nB \u003c- 4  # number of runs\nnc \u003c- 2 # number of cores\n\n## sequential\nsystem.time(bb \u003c- b$replicate(B, cl=NULL))\n\n## parallel clusters\ncl \u003c- makeCluster(nc)\n## note: loading the package is optional\nsystem.time(clusterEvalQ(cl, library(bSims)))\nsystem.time(bb \u003c- b$replicate(B, cl=cl))\nstopCluster(cl)\n\n## parallel forking\nif (.Platform$OS.type != \"windows\") {\n  system.time(bb \u003c- b$replicate(B, cl=nc))\n}\n```\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpsolymos%2Fbsims","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpsolymos%2Fbsims","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpsolymos%2Fbsims/lists"}