Every complete example in this document is available in a zip file that you can download. The zip file includes a SQL script file that creates the input tables for the examples. If you are reading this document on https://docs.teradata.com/, you can download the zip file from the attachment in the left sidebar.
TD_SHAP requires an input table and a model table to output the feature contribution based on calculated Shapley values. The Shapley value is calculated as average marginal contribution of a feature value across all possible coalitions.