draft of the R package