Hi!
I'm trying to use this formula to calculate eGFR: eGFR = 142*min(standardized Scr/K, 1)^α *max(standardized Scr/K, 1)^-1.200 *0.9938Age *1.012 [if female]
Scr= creatinine, e.g. creatinine=2.4.
In this formula, the min(standardized Scr/K, 1) means that you either choose the creatinine value divided by kappa, OR 1. The same goes for the max-one.
I'm looking for advice on how to write the command so Stata realizes this. Grateful for any help!
Related Posts with Writing a formula in which stata chooses a value or 1
graph pie with some of percentagesHow to display the fraction when percentage is above 20%, I know how to display all percentages Cod…
Year fixed effectsHello everyone, I am running a panel data regression model in which I observe 4 time periods and 66 …
regression result only except first variableHello When I regress as below, why don't I get the result for the first variable and how can I fix …
Oaxaca decomposition for nonlinear regression (nldecompose)Hello readers, I am trying to decompose (using Ben Jann’s nldecompose) differences in the probabilit…
GenerateI am using two data set, one contains data for children and another for woman. Now both data sets ha…
Subscribe to:
Post Comments (Atom)
0 Response to Writing a formula in which stata chooses a value or 1
Post a Comment