LTspice: How to make a time-variant mutual inductance coefficient in transformer model
For a standard inductor, unfortunatley it looks like you can not. The internal model of an inductor (non chan) looks roughly like (taken from the ltwikis site about transformers):



Note how the K factor is used to split the inductance between the mutually coupled and the leakage inductance. In theory if it would be just the K statement not supporting\$^*\$ any input variables you could use that one to directly set the inductance values.

Unfortunately, although it accepts a lot of functions to set the inductance value, inductors can not depend in any way on any time varying functions.

The same seems to hold true for chan inductors, though I never played enough with them to be absolutely sure. It seems that most (all?) spice dialects do need to calculate some internal numbers for an inductor before starting a transient analysis. Probably nobody bothered to do this on demand for each timestep (or probably this is even too computationally expensive).



\$^*\$ It is evidently evaluating the factor at the start/before op point search, as indicated by the following message in the log when you try to set it outside the allowed range:

Reducing mutual coupling coefficient from 3 to 1.