Hello,

I'm looking for a way to solve this equation in Stata:

0.1(w+2000000)^(1-r) + 0.9(w-z)^(1-r) = w^(1-r)

where w = individual income
z= willingness to pay for a lottery

I'd like to find r that is the risk preference coefficient.
The data set is at individual level.

Thank you very much for your help!