## Description: one-compartment model with dosepoint1 being IV infusion and dosepoint2 being IV infusion 


## DATA OneCpt_dosepoint1IVInfusion_dosepoint2IVInfusion.csv

## MAP id = Subject time CObs = DV

## COLDEF
dose(A1 <- "Dose1", duration = "Duration1")
dose2(A1 <- "Dose2", duration = "Duration2")

## MODEL
test(){
	deriv(A1 = - Cl * C)
	dosepoint(A1)
	dosepoint2(A1, tlag = 12)
	C = A1 / V
	
	##===========================================
	## Residual error model
	##===========================================
	error(CEps = 0.1)
	observe(CObs = C * (1 + CEps))
	
	##===========================================
	## Model parameters
	##===========================================
	stparm(V = tvV * exp(nV))
	stparm(Cl = tvCl * exp(nCl))
	fixef(tvV = c(, 5, )) # true value: 4.5
	fixef(tvCl = c(, 1, )) # true value: 1.2
	ranef(diag(nV, nCl) = c(1, 1)) # true value: c(0.1, 0.1)
}


## ESTARGS
# numIterations = 1
# stdErr = "None"
