Nothing
updata <-
function(data = data, lastdose, npt, ndlt){#browser()
if (!(lastdose %in% data$dose)) {stop("dose do not treat")}
if (ndlt > npt) {stop("ndlt > npt is impossible")}
if (npt == 0){return(data)}
if (ndlt < 0 | npt < 0) {stop("ndlt & npt must be positive")}
idx<-which(data$dose==lastdose)
data[idx, "npt"] <- data[idx,"npt"] + npt
data[idx, "ndlt"] <- data[idx,"ndlt"] + ndlt
return(data)
}
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.