The following example shows how it implement a transfer function for a close loop control.
Example code from the Example Code Exchange in the NI Community is licensed with the MIT license.