Research Article

FB2Droid: A Novel Malware Family-Based Bagging Algorithm for Android Malware Detection

Algorithm 1

The basic flow of the bagging algorithm.
Input: Dataset D, number of iterations T, number of sampling n, base classifier G(x)
Output: The final strong classifier f(x)
(1)for t = 1, 2, …, T;
(2)The training set D is randomly sampled for the tth time, and a total of m times are taken to obtain a sampling subset Dt containing m samples.
(3)Training the base classifier Gt(x) using the sample set Dt.
(4)If it is a classification algorithm, the voting strategy is adopted, that is, the category or one of the categories with the most votes cast by T base classifiers is the final classification. If it is a regression algorithm, the arithmetic mean is adopted, i.e., the arithmetic mean is performed on the regression results obtained by T weak classifiers, and the value obtained is the final model output.