In short.. using SetAV is the same as if you opened the npc in the geck and changed the number on the tab yourself. It will affect everything that comes after so use only when absolutely necessary.
I'd say the preferred way to temporarily modify stats is via DamageAV and RestoreAV. Those will change the game modifier value for the stat, will be remembered in the save game, can have the changes it makes reversed by other ingame modifications like acquiring health, perks, bobbleheads, etc.., and shouldn't cause any issues in stat calculation for things like perks, other mods, and whatnot.
Next best way is probably ModAV used in a script, but is better suited for permanently changing a stat without the risk that SetAV brings. ModAV changes the script modifier for that stat, is remembered in the save game, but the changes made can
only be reverted by another ModAV script call.