<img src="">

Gtk medication dosage calculators for Julia


First you should define a function which takes named arguments weight = kg, height = cm, and age = years.

See the file examples/Medications.jl for examples of formulas.

This type of app does not consider concomitant medications. If there are such issues, consider mention in the text of rlabel. <br /><br />

<em>Always</em> sanity check medical apps for errors! Unchecked unit or decimal place errors <em>can kill!</em>

<br /><br />


dose_calculator_app(func::Function, title = "Dose Calculator", rlabel = "Results")

Create a Gtk widget with entries for weight, height, age, and dose interval. Arguments: func is a function which takes named arguments age = years, weight = kg, height = cm and returns total 24-hour dosage in mg. title is the title for the app rlabel is the label to be given the results <br /><br />


using DoseCalculators
function amoxicillin_po(; age, weight, height)
    if age <= 3/12
        return weight * 30.0
    elseif age <= 16 && weight <= 40
        return weight * 37.0
        return 1500.0
dose_calculator_app(amoxacillin_po, "Amoxacillin PO Dosing", "Amoxacillin dosage(mg)")

See the examples directory for other examples of formulas. <br /><br />


You may install the package from Github in the usual way: <br />

# press ] to go to Pkg mode

pkg> add DoseCalculators

<br />

Or, to install the current master copy:

using Pkg

<br />