Add transform variables function