Skip to content
Snippets Groups Projects
Commit 665bd675 authored by dj44vuri's avatar dj44vuri
Browse files

small changes in vignettes and manual tests

parent fc4394bf
No related branches found
No related tags found
No related merge requests found
rm(list=ls())
devtools::load_all()
designpath<- system.file("extdata","agora" ,package = "simulateDCE")
resps =360 # number of respondents
......
......@@ -18,10 +18,10 @@ nosim=1000 # number of simulations to run (about 500 is minimum)
bcoeff<-list(
bx1 = -0.2,
bx2 = -0.2,
bx3 = -0.1,
bx4 = -0.05)
bx1 = -0.1,
bx2 = -0.1,
bx3 = -0.05,
bx4 = -0.025)
destype <- "spdesign"
......@@ -31,7 +31,7 @@ destype <- "spdesign"
ul<- list(u1= list(
v1 =V.1 ~ bx1 * alt1.x1 + bx2 * alt1.x2 + bx3 * alt1.x3 + bx4 * alt1.x4,
v2 =V.2 ~ bx1 * alt2.x1 + bx2 * alt2.x2 + bx3 * alt2.x3 + bx4 * alt2.x4,
v3 =V.3 ~ -10
v3 =V.3 ~ -5
)
)
......
......@@ -50,7 +50,7 @@ library(rlang)
# Inititalize Variables
sim_all is the highest level function in the package and will run simulations for all designs contained in the specified design folder. Accordingly, this is generally the function the user will want to call. To prepare for using this function, a hypothesized utility function with cooresponding beta coefficients representing the weight of each term must be declared in R like so:
sim_all is the highest level function in the package and will run simulations for all designs contained in the specified design folder. Accordingly, this is generally the function the user will want to call. To prepare for using this function, a hypothesized utility function with corresponding beta coefficients representing the weight of each term must be declared in R like so:
```{r initialize}
......@@ -104,7 +104,7 @@ destype="ngene"
# Output
The sim_all function returns a multidimensional R list containing graphs, simulated observations and a dataframe containing sumaries of estimated b coefficients. In general these will be printed to the console, but the entire results can also be assigned to an r variable.
The sim_all function returns a multidimensional R list containing graphs, simulated observations and a dataframe containing sumaries of estimated b coefficients. In general these will be printed to the console, but the entire results can also be assigned to an r list object.
```{r output}
sedrive <- sim_all(nosim = nosim, resps=resps, destype = destype,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment