Skip to content

Commit

Permalink
replace unit conversion example in the vignette to avoid the unicode …
Browse files Browse the repository at this point in the history
…issue on AppVeyor (#1399)

Co-authored-by: Yuri05 <Yuri05@github.com>
  • Loading branch information
Yuri05 and Yuri05 authored Apr 23, 2024
1 parent 1856d4a commit 03e8f5a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions vignettes/unit-conversion.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -54,18 +54,18 @@ The `{ospuite}` package provides a set of methods for conversion between differe

```{r unitConversion}
# Get the BMI parameter
bmiParam <- getParameter("Organism|BMI", sim)
print(bmiParam)
heightParam <- getParameter("Organism|Height", sim)
print(heightParam)
# Print the base and the default display units
bmiParam$unit
bmiParam$displayUnit
heightParam$unit
heightParam$displayUnit
# Convert the value from the base into the default display unit
toDisplayUnit(quantity = bmiParam, values = bmiParam$value)
toDisplayUnit(quantity = heightParam, values = heightParam$value)
# Convert the value to the base unit, that can be used. e.g. for setting new parameter value
toBaseUnit(quantity = bmiParam, values = 30, unit = "kg/m²")
toBaseUnit(quantity = heightParam, values = 180, unit = "cm")
liverVolume <- getParameter("Organism|Liver|Volume", sim)
print(liverVolume)
Expand Down

0 comments on commit 03e8f5a

Please sign in to comment.