Python Assign Method To Variable Resistor