Generate expressions suitable plot legends describing system conditions.
lNaCl(x, digits = 2)
lS(x, digits = 3)
lT(x, digits = 0)
lP(x, digits = 0)
lTP(x, y, digits = 0)
lex(...)
numeric, value of the property
numeric, digits for rounding
numeric, value of pressure
language, objects to combine in an expression
These functions are used to make expressions for common chemical system variables that can be used in plot legends.
lNaCl
describe the molality of NaCl, and lS
the total molality of sulfur.
lT
and lP
describe the temperature and pressure.
lTP
describe the temperature and pressure together, separated by a comma.
The above functions return language objects, which can be combined with lex
to make an expression that when used in legend
appears on multiple lines.
# NOT RUN {
plot.new()
l <- lex(lTP(100, "Psat"), lNaCl(1), lS(1e-3))
legend("center", l)
# }
Run the code above in your browser using DataLab