Update TransferFunction Code.R