Research Article
Service-Life Study of Polycarbonate Outdoors Using Python with Incomplete Data
Input: Training Set ; | Attribute Set . | Process: Function | 01: generate the node | 02: if all samples in belong to the same class then | 03: sign the node as a leaf node of class; return | 04: end if | 05: ifor samples in have the same value of then | 06: sign the node as a leaf node of the class which the most samples in belong to; return | 07: end if | 08: select the optimal attribute; | 09: for every value of do | 10: generate a branch for the node; | make be a subaggregate of samples in with the value of; | 11: ifthen | 12: sign the branch node as a leaf node of the class which the most samples in belong to; return | 13: else | 14: sign as a branch node | 15: end if | 16: end for | Output: a decision tree with the root node. |
|