Description Usage Arguments Value Note Examples

Generates a `data.frame`

or `data.table`

with a binary outcome, and a logistic model to
describe it.

1 2 3 4 5 6 7 | ```
genBinomDf(b = 2L, f = 2L, c = 1L, n = 20L, nlf = 3L, pb = 0.5,
rc = 0.8, py = 0.5, asFactor = TRUE, model = FALSE, timelim = 5,
speedglm = FALSE)
genBinomDt(b = 2L, f = 2L, c = 1L, n = 20L, nlf = 3L, pb = 0.5,
rc = 0.8, py = 0.5, asFactor = TRUE, model = FALSE, timelim = 5,
speedglm = FALSE)
``` |

`b` |
The number of |

`f` |
The number of |

`c` |
The number of |

`n` |
The |

`nlf` |
The |

`pb` |
The |

`rc` |
The |

`py` |
The |

`asFactor` |
If |

`model` |
If |

`timelim` |
function will timeout after |

`speedglm` |
If |

If `model=TRUE`

: a list with the following values:

`df or dt` |
A |

`model` |
A model fit with |

If `model=FALSE`

a `data.frame`

or `data.table`

as above.

`genBinomDt`

is faster
and more efficient for large datasets.

Using `asFactor=TRUE`

with `factor`

s
which have a large number of `levels`

(e.g. `nlf > 30`

)
on large datasets (e.g. *n > 1000*)
can cause fitting to be excessively slow.

1 2 3 | ```
set.seed(1)
genBinomDf(speedglm=TRUE)
genBinomDt(b=0, c=2, n=100L, rc=0.7, model=FALSE)
``` |

dardisco/LogisticDx documentation built on May 12, 2017, 5:37 p.m.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.