Assign in editor or in scritp

Hi,
is there a difference between assigning a var in editor (via drag’n’drop), and in script?
I mean
scritp

var texture: Texture;

function set()
{
texture=load resource or so
}

and in editor assigning.
I have one script which uses a lot of textures and guitextures and it uses a lot of memory, so I’m trying to find how to optimise it,
thnx

the only difference is that the editor set ones are available right from the moment of awake while script set ones likely are avaible at earliest in start for cross referencing.

but other than that, a reference is a reference, independent of where it comes from