EppicParam

class PlasmaCalcs.hookups.eppic.eppic_choose_params.EppicParam(value, *, old=None, fmt='{:}')

Bases: object

a value for a single eppic parameters.

Also with instructions for converting to str, and info about the old value.
value: any
value to use for this parameter.
old: any
old value for this parameter.
fmt: str
instructions for formatting the value.
when this object is converted to str, will return fmt.format(value).

Methods

eval_str_old()

returns result of evaluating self.str_old().

eval_str_value()

returns result of evaluating self.str_value().

fmt_str(value)

returns self.fmt.format(value), or '0' if value==0.

str_old()

returns self.fmt_str(self.old), or 'None' if self.old is None

str_value()

returns self.fmt_str(self.value)

eval_str_old()

returns result of evaluating self.str_old().

Might be different from old, due to rounding when converting to string.
eval_str_value()

returns result of evaluating self.str_value().

Might be different from value, due to rounding when converting to string.
fmt_str(value)

returns self.fmt.format(value), or ‘0’ if value==0.

str_old()

returns self.fmt_str(self.old), or ‘None’ if self.old is None

str_value()

returns self.fmt_str(self.value)