nlmixr2 / rxode2et

https://nlmixr2.github.io/rxode2et/
1 stars 1 forks source link

33 reading dataset with rate = 2 #34

Closed mattfidler closed 10 months ago

mattfidler commented 10 months ago

Works with this pull request

  library(rxode2et)
  d <- data.frame(id = c(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1),
       time = c(0, 2, 12.5, 24.5, 37, 48, 60.5, 72.5, 85.3, 96.5, 108.5, 112.5), 
       amt = c(25, 0, 3.5, 3.5, 3.5, 3.5, 3.5, 3.5, 3.5, 3.5, 3.5, 0),
       rate = c(-2, 0, -2, -2, -2, -2, -2, -2, -2, -2, -2, 0))
  et(d)
#> ── EventTable with 12 records ──
#> 10 dosing records (see x$get.dosing(); add with add.dosing or et)
#> 2 observation times (see x$get.sampling(); add with add.sampling or et)
#> ── First part of x: ──
#> # A tibble: 12 × 5
#>       id  time   amt rate       evid         
#>    <int> <dbl> <dbl> <rate/dur> <evid>       
#>  1     1   0    25   -2:dur     1:Dose (Add) 
#>  2     1   2    NA   NA         0:Observation
#>  3     1  12.5   3.5 -2:dur     1:Dose (Add) 
#>  4     1  24.5   3.5 -2:dur     1:Dose (Add) 
#>  5     1  37     3.5 -2:dur     1:Dose (Add) 
#>  6     1  48     3.5 -2:dur     1:Dose (Add) 
#>  7     1  60.5   3.5 -2:dur     1:Dose (Add) 
#>  8     1  72.5   3.5 -2:dur     1:Dose (Add) 
#>  9     1  85.3   3.5 -2:dur     1:Dose (Add) 
#> 10     1  96.5   3.5 -2:dur     1:Dose (Add) 
#> 11     1 108.    3.5 -2:dur     1:Dose (Add) 
#> 12     1 112.   NA   NA         0:Observation

Created on 2023-12-07 with reprex v2.0.2

codecov[bot] commented 10 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (62b83ed) 62.13% compared to head (8df469f) 62.16%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #34 +/- ## ========================================== + Coverage 62.13% 62.16% +0.03% ========================================== Files 21 21 Lines 4027 4028 +1 ========================================== + Hits 2502 2504 +2 + Misses 1525 1524 -1 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.