Craft Commerce update variant field in plugin
This is the general mechanism for updating custom fields on elements - use setContentFromPost and then call the element's save function.

    $variant-&gt;setContentFromPost(array(
        'fieldHandle' =&gt; $newValue,
    ));
    craft()-&gt;commerce_variants-&gt;saveVariant($variant);


You should catch exceptions around that really, to handle any errors that may arise (as the model gets validated during save etc.)