The invention discloses a method and a
system for quantitatively estimating the
code size of new requirements based on
weight adjustment. The method comprises the following steps of: performing characteristic extraction according the conventional N requirements of a
software project; selecting the characteristic extraction data of m requirements, setting the characteristic extraction data of each requirement to be RSi, setting an adjustment parameter gamma of the
software project to be 1 and calculating an estimated value ESi of the
code size of the requirement RSi; calculating the ratios gammai of each estimated value to a real value, and taking the value of the adjustment parameter gamma as an average value of all the ratios gammai; performing the characteristic extraction on the new requirements of the
software project; calculating distances Dij between each new requirement Rnewi and the conventional requirements; calculating the weight Wij of influence among the requirements; and calculating the estimated value Ei of the
code size of the new requirements Rnewi according to a formula. In the method of the invention, similarity between the new requirements and the conventional requirements of the software project is calculated, and the characteristic data of all the conventional requirements is used, so the to-be-generated code size of the new requirements can be accurately quantized.