Functional analysis of immune subtypes in hepatocellular carcinoma has attracted much attention due to its advantages in solving some optimization problems. At present, the research on the immune subtype of hepatocellular carcinoma is still in its infancy, and the high stability of its system still has problems. Based on fuzzy logic and evolutionary algorithms, this paper constructs a Mate analysis of the optimization problem of immune subtypes and dynamic optimization problems of hepatocellular carcinoma. The model conducts in-depth analysis and research on the biological immune subtype system, solving the problems of reliable information processing and body defense. Tested with existing test functions, very competitive results were achieved. The simulation results show that the improved algorithm based on data statistics has global search ability, the solution accuracy reaches 0.931, and the stability reaches 88.1%.