Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Jan 15, 2025. It is now read-only.
/simsPublic archive
forked fromaudrey-b/sims

An R package to simulate data from JAGS or R Code

License

NotificationsYou must be signed in to change notification settings

poissonconsulting/sims

 
 

Repository files navigation

Lifecycle: stableR-CMD-checkCodecovLicense: MITCRAN statusCRAN downloads

sims is an R package to generate datasets from R orJAGS code for use in simulationstudies. The datasets are returned as annlists object and/or savedto file as individual .rds files. Parallelization is implemented usingthefuture package.Progress is reported using theprogressr package.

Installation

You can install the released version of sims fromCRAN with:

install.packages("sims")

And the development version fromGitHub with:

# install.packages("remotes")remotes::install_github("poissonconsulting/sims")

Demonstration

Simulate Data

By default,sims_simulate() returns the simulated datasets in the formof annlists object.

library(sims)set.seed(10)sims_simulate("a <- runif(1)",nsims=2L)#> $a#> [1] 0.2213763#>#> an nlists object of 2 nlist objects each with 1 numeric element

If, however,save = TRUE then each nlist object is saved as an.rdsfile inpath.

set.seed(10)sims_simulate("a <- runif(1)",nsims=2L,save=TRUE,path= tempdir(),exists=NA)#> [1] TRUEsims_data_files(tempdir())#> [1] "data0000001.rds" "data0000002.rds"sims_data(tempdir())#> $a#> [1] 0.2213763#>#> an nlists object of 2 nlist objects each with 1 numeric element

Information

For more information see theGetStartedvignette.

Contribution

Please report anyissues.

Pull requests arealways welcome.

Code of Conduct

Please note that the sims project is released with aContributor CodeofConduct.By contributing to this project, you agree to abide by its terms.

About

An R package to simulate data from JAGS or R Code

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

No packages published

Languages

  • R100.0%

[8]ページ先頭

©2009-2025 Movatter.jp