MyNixOS website logo
Description

Adaptation of Virtual Twins Method from Jared Foster.

Research of subgroups in random clinical trials with binary outcome and two treatments groups. This is an adaptation of the Jared Foster method (<https://www.ncbi.nlm.nih.gov/pubmed/21815180>).

aVirtualTwins

CRAN_Status_Badge

An adaptation of VirtualTwins method from Foster, J. C., Taylor, J. M.G. and Ruberg, S. J. (2011)

VirtualTwins is a method of subgroup identification from randomized clinical trial data.

In 2015, as an intern in a french pharmaceutical group, i worked on this method and develop a package based on Jared Foster and al method.

(Very) Quick Preview

# Load data
data(sepsis)
# Format data
vt.obj <- vt.data(dataset         = sepsis,
                  outcome.field   = "survival",
                  treatment.field = "THERAPY",
                  interactions    = TRUE)
# Print Incidences of sepsis data
vt.obj$getIncidences()
# $table
#            trt
# resp        0    1     sum  
#   0         101  188   289  
#   1         52   129   181  
#   sum       153  317   470  
#   Incidence 0.34 0.407 0.385
#
# $rr
# [1] 1.197059
#
# First step : create random forest model
vt.for <- vt.forest(forest.type  = "one",
                    vt.data      = vt.obj,
                    interactions = TRUE,
                    ntree        = 500)
# Second step : find rules in data 
vt.trees <- vt.tree(tree.type = "class",
                    vt.difft  = vt.for, 
                    threshold = quantile(vt.for$difft, seq(.5,.8,.1)),
                    maxdepth  = 2)
# Print results
vt.sbgrps <- vt.subgroups(vt.trees)
knitr::kable(vt.sbgrps)
SubgroupSubgroup sizeTreatement event rateControl event rateTreatment sample sizeControl sample sizeRR (resub)RR (snd)
tree1PRAPACHE>=26.51570.7520.327105522.3001.856
tree3PRAPACHE>=26.5 & AGE>=51.741200.8970.3178422.8941.991

Infos

Currently this package works for RCT with two treatments groups and binary outcome.

Most of the package use Reference Class programing (in R). Feel free to create your own classes.

Of course, subgroup identification in general with two treatment and severals group can be possible.

Help & Documentation

See wiki tab.

Or:

vignette("full-example", package = "aVirtualTwins")

Or:

Here's a link to my intern dissertation (french version) La recherche de sous-groupes par Virtual Twins (parts V & VI).

Install

# use devtools library
library(devtools)
# install from github
devtools::install_github("prise6/aVirtualTwins", build_vignettes = TRUE)
# load library
library(aVirtualTwins)

To-do list

  • Link to my simulation
  • Submit to CRAN
  • Use R6 for perfs issues
  • Vignette on-line

News

See NEWS file

Contact

vieille.francois at gmail.com.

Metadata

Version

1.0.1

License

Unknown

Platforms (75)

    Darwin
    FreeBSD 13
    Genode
    GHCJS
    Linux
    MMIXware
    NetBSD
    none
    OpenBSD
    Redox
    Solaris
    WASI
    Windows
Show all
  • aarch64-darwin
  • aarch64-genode
  • aarch64-linux
  • aarch64-netbsd
  • aarch64-none
  • aarch64_be-none
  • arm-none
  • armv5tel-linux
  • armv6l-linux
  • armv6l-netbsd
  • armv6l-none
  • armv7a-darwin
  • armv7a-linux
  • armv7a-netbsd
  • armv7l-linux
  • armv7l-netbsd
  • avr-none
  • i686-cygwin
  • i686-darwin
  • i686-freebsd13
  • i686-genode
  • i686-linux
  • i686-netbsd
  • i686-none
  • i686-openbsd
  • i686-windows
  • javascript-ghcjs
  • loongarch64-linux
  • m68k-linux
  • m68k-netbsd
  • m68k-none
  • microblaze-linux
  • microblaze-none
  • microblazeel-linux
  • microblazeel-none
  • mips-linux
  • mips-none
  • mips64-linux
  • mips64-none
  • mips64el-linux
  • mipsel-linux
  • mipsel-netbsd
  • mmix-mmixware
  • msp430-none
  • or1k-none
  • powerpc-netbsd
  • powerpc-none
  • powerpc64-linux
  • powerpc64le-linux
  • powerpcle-none
  • riscv32-linux
  • riscv32-netbsd
  • riscv32-none
  • riscv64-linux
  • riscv64-netbsd
  • riscv64-none
  • rx-none
  • s390-linux
  • s390-none
  • s390x-linux
  • s390x-none
  • vc4-none
  • wasm32-wasi
  • wasm64-wasi
  • x86_64-cygwin
  • x86_64-darwin
  • x86_64-freebsd13
  • x86_64-genode
  • x86_64-linux
  • x86_64-netbsd
  • x86_64-none
  • x86_64-openbsd
  • x86_64-redox
  • x86_64-solaris
  • x86_64-windows