An index automatic fitting method based on principal component analysis
Patent Information
- Application Number
- CN202610809681.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-05
- Publication Date
- 2026-08-28
AI Technical Summary
[0003]本发明的目的是提供一种基于主成分分析的指标自动拟合方法,能够解决PCA在多指标拟合中的结果不唯一的问题,实现模型的自动化智能化运行
[0003] The purpose of this invention is to provide an automatic index fitting method based on principal component analysis, which can solve the problem that the results of PCA in multi-index fitting are not unique, and realize the automated and intelligent operation of the model.
Smart Images

Figure CN122654643A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of statistical econometrics, and in particular to an automatic fitting method for multi-index influencing factors based on principal component analysis, without prior assumptions. Background Technology
[0002] Currently, Principal Component Analysis (PCA), first proposed by British statistician Carl Pearson, uses orthogonal transformations to convert correlated variables into uncorrelated ones, addressing data simplification issues in statistical analysis. This method utilizes the core algorithm logic of eigenvalue decomposition of the covariance matrix to solve for principal components, giving PCA a clear mathematical process and significant implications for simplifying multi-indicator data. Unlike regression analysis and clustering algorithms, PCA does not require prior assumptions about data distribution (e.g., normal distribution) or variable relationships; it relies solely on the variance and covariance structure of the data, making it adaptable to data analysis scenarios in various fields such as statistics, machine learning, remote sensing, and bioinformatics. Taking comprehensive ecological environment quantitative assessment as an example, when using PCA for indicator fitting, the PCA solution process essentially involves solving for an orthogonal symmetric matrix (covariance matrix). Each principal component of an orthogonal symmetric matrix corresponds to two eigenvectors of equal magnitude but opposite directions, exhibiting significant randomness and uncertainty. Changes in the input order of indicators or the data source can lead to different results. Figure 1 As shown, the direction of this feature vector does not affect the dimensionality reduction result, but when performing index fitting, this direction directly determines the direction of the index's effect on the dependent variable. Due to the non-uniqueness and randomness of the feature vector direction, the index fitting result also randomly produces two opposite results. This means that when using PCA to fit the index, each result requires manual intervention, making batch calculation and automated operation impossible. Summary of the Invention
[0003] The purpose of this invention is to provide an automatic index fitting method based on principal component analysis, which can solve the problem that the results of PCA in multi-index fitting are not unique, and realize the automated and intelligent operation of the model.
[0004] This invention proposes an automatic index fitting method based on principal component analysis. By specifying an index with a clear and significant impact on the dependent variable as a Flag index (e.g., NDVI has a significant positive impact on the ecological environment), the direction of the eigenvector is modified according to the direction (positive or negative) of the Flag index in the random vector corresponding to the principal component obtained during the solution process, ensuring that the fitting result is unique and meets expectations each time. Then, the eigenvector (weight) of each principal component is automatically determined according to the value of each index corresponding to the eigenvector, and the number of principal components is selected according to the contribution rate of the eigenvalues of each principal component. Finally, a linear multi-index automatic fitting model is constructed, realizing the rapid fitting of multiple index factors into a comprehensive index. Attached Figure Description
[0005] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0006] Figure 1 This is a diagram showing the comparison of results for different input orders of the indicators described in this application;
[0007] Figure 2 This is a schematic diagram of the original calculation results of the ecological environment quality described in this application;
[0008] Figure 3 This is a schematic diagram of the corrected ecological environment quality results described in this application;
[0009] Figure 4 This is a flowchart of the present invention. Detailed Implementation
[0010] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0011] This invention includes the following steps:
[0012] Step 1: Characteristic Vector Direction Determination: Based on expert experience or relevant analysis methods, select indicators with clear and significant influence directions from the indicator system affecting the dependent variable y as Flag indicators. During each Principal Component Analysis (PCA) operation, determine the direction of the characteristic vectors of each principal component based on the direction of the Flag indicators, ensuring that the indicator components corresponding to the characteristic vectors of each principal component can stably serve as fitting weights. The relevant analysis methods include expert scoring or Pearson correlation analysis. Step 1 specifically includes:
[0013] S1.1 Setting Indicators ,…, For a system of indicators influencing a dependent variable y, based on expert experience and / or relevant analysis methods, identify the Flag indicator that has the most significant impact on the dependent variable y and whose direction of influence is clearly defined. This Flag indicator is denoted as... , where 1≤i≤n, and record whether its influence on the dependent variable y is positive or negative;
[0014] S1.2 Inversion Indicators ,…, The original index matrix U is formed.
[0015]
[0016] S1.3 standardizes each index in the original matrix. The standardization formula is as follows:
[0017]
[0018] In the formula, for Indicator pixels exist The dimensionless result of time; Refers to the pixel exist At any moment The raw data for the indicator; and It is an indicator Maximum and minimum values under all spatiotemporal conditions.
[0019] The standardized matrix is,
[0020]
[0021] S1.4 Based on standardized data, the correlation coefficient matrix R between indicators is calculated, and the correlation coefficient matrix is decomposed to obtain eigenvalues and eigenvectors, where:
[0022] The eigenvector is denoted as : , ,… … , The contribution rate of eigenvalues is denoted as...
[0023] The eigenvector is denoted as : , ,… … , The contribution rate of eigenvalues is denoted as...
[0024] ...
[0025] The eigenvector is denoted as : , ,… … , The contribution rate of eigenvalues is denoted as... .
[0026] In step 1, the influence direction of the Flag index includes positive and negative correlation, and the direction of the feature vector is uniformly corrected based on the direction of the Flag index in the subsequent principal component direction analysis.
[0027] Step 2, adaptive selection of cumulative contribution rate of principal component eigenvalues: Based on the cumulative contribution rate threshold N set according to research needs, adaptively select the number m of principal components participating in the fitting, so that the cumulative contribution rate of the eigenvalues of the first m principal components is not lower than the threshold N; Step (2) specifically includes:
[0028] Based on research needs, a cumulative contribution rate threshold N is set, and the principal components obtained from a single principal component calculation are defined as follows: , …, The corresponding eigenvalue contribution rates are respectively , …, The corresponding feature vectors are respectively , …, According to research requirements, the cumulative contribution rate must be ≥ N, then:
[0029] (1)
[0030] In the formula, , …, N represents the contribution rate of the eigenvalues corresponding to each principal component in the principal component operation, and N is the minimum cumulative contribution rate that needs to be satisfied in practical applications.
[0031] Step 3, Automatic Model Fitting: Based on the determined number of principal components m and the Flag index, the index fitting result Result is automatically obtained. Step (3) specifically includes:
[0032] Let the eigenvectors be... The corresponding indicator components are respectively Then there is a Flag indicator. In the eigenvector The components in are Based on the Flag indicators determined in the previous steps Given the number of principal components m, where 1 ≤ m ≤ n, construct an auto-fit principal component model:
[0033] If Flag indicator As a positive index of the dependent variable y:
[0034] (2)
[0035] (3)
[0036] If Flag indicator It is the negative index of the dependent variable y:
[0037] (4)
[0038] (5)
[0039] In the formula, This is the result of fitting the first principal component. The fitting result for the nth principal component is... For the nth principal component, the index In the eigenvector The corresponding index component values are m, where m refers to the cumulative contribution rate of the first m principal components that satisfy the preset feature values. Result is the result of index fitting.
[0040] To address the issue of PCA failing to batch process data due to the random occurrence of two equal-sized but opposite-directed results when assigning indicator weights, this invention proposes designating the indicator with the most explicit and significant influence on the dependent variable as the Flag indicator. Based on the direction of the Flag indicator in the random eigenvectors during each principal component analysis, the direction of each principal component's eigenvector is determined. This ensures that the magnitude and direction of each indicator component corresponding to the eigenvector of each principal component in each calculation can serve as the weight for fitting that indicator, thereby enhancing the automation and generalization capabilities of PCA's indicator fitting.
[0041] This invention also discloses a system for automatic index fitting based on principal component analysis, which mainly includes three modules: eigenvector judgment, adaptive screening of cumulative contribution rate of component eigenvalues, and automatic index fitting module, as detailed below:
[0042] (1) Feature vector direction analysis module
[0043] The feature vector direction determination module is the core foundation for achieving automated model operation. Its core objective is to solve the automation bottleneck problem caused by weight uncertainty in traditional PCA. The specific implementation process is as follows:
[0044] ① Preliminary indicator screening. Within the established comprehensive indicator system, combining domain expert experience with statistical analysis methods (such as correlation analysis, significance testing, expert scoring, etc.), indicators with a clear direction of influence on the dependent variable and significant impact are screened and defined as Flag indicators. The core function of these indicators is to serve as "benchmark anchors" for judging the direction of eigenvectors, providing a clear basis for determining the direction of subsequent principal components.
[0045] ② Directional Co-verification. During each principal component analysis operation, using the selected Flag index as a benchmark, the directional co-verification mechanism is employed to determine the direction of the eigenvectors corresponding to each principal component. This ensures that the direction of the component eigenvector corresponding to the Flag index is consistent with the known influence direction of the Flag index on the dependent variable, thereby locking in the directional uniqueness of the eigenvectors.
[0046] By implementing this module, the index components corresponding to the principal component eigenvectors can be stably used as the core weights for subsequent fitting, avoiding the weight uncertainty problem caused by random fluctuations in the eigenvector direction in traditional PCA, and laying the core technical foundation for the automation and batch operation of the entire scheme.
[0047] (2) Adaptive screening module for cumulative contribution rate of principal component eigenvalues
[0048] The core objective of the adaptive screening module for the cumulative contribution rate of principal component eigenvalues is to adaptively determine the number of principal components participating in the fitting of subsequent indicators based on actual research needs, ensuring a balance between the explanatory power and conciseness of the fitted model. The specific implementation process is as follows:
[0049] ① Demand Preset. Based on the explanatory power requirements of the specific research scenario, preset the cumulative contribution rate threshold of principal component eigenvalues (such as 85%, 90%, etc.). This threshold represents the proportion of sample information that the fitting model needs to cover.
[0050] ② Adaptive Calculation and Screening. After obtaining the eigenvalues and corresponding contribution rates of each principal component through principal component analysis, the eigenvalues of the principal components are cumulatively calculated in descending order of contribution rate to screen out the top m principal components, ensuring that the cumulative contribution rate of the eigenvalues of these m principal components is greater than or equal to a preset threshold. For example, if the preset threshold is 85%, the minimum value of m is determined through cumulative calculation to ensure that the top m principal components can explain at least 85% of the sample information.
[0051] This module determines the number of principal components through a "demand-oriented + data-adaptive" approach. This ensures that the fitted model fully covers the sample information while avoiding excessive model complexity caused by introducing too many redundant principal components, thus improving the practicality and efficiency of the fitted model.
[0052] (3) Automatic index fitting module
[0053] The automatic indicator fitting module is the final implementation module of the solution. Based on the output results of the first two modules, it completes the automatic fitting of indicators. The specific implementation process is as follows:
[0054] ① Input parameter confirmation. Obtain the core output parameters of the preceding modules, including the stable feature vector (including the weights of each indicator) locked by the feature vector direction analysis module, the number of principal components m determined by the principal component screening module, and the Flag indicator as the benchmark.
[0055] ② Fitting Calculation. Based on a preset fitting algorithm (such as linear fitting, weighted fitting, etc.), using stable principal component feature vectors as weights and the selected m principal components as core inputs, the algorithm automatically completes the fitting calculation of the target index under the directional constraint of the Flag index and outputs the final fitting result.
[0056] This module automates the entire index fitting process without requiring manual intervention in weight determination and principal component selection, effectively reducing manual operation costs and errors. At the same time, relying on the stable output of the preceding modules, it ensures the reliability of the fitting results and provides direct support for the standardization and streamlining of subsequent data processing.
[0057] For example, in remote sensing ecological environment assessment, scholars currently still use ecological environment assessment indicators such as NDVI, NDBSI, LST, and WET derived from remote sensing images of a specific period. Due to the non-uniqueness and automation level of PCA calculation results, scholars often use the calculation results from a single image in October to represent the ecological environment quality for the entire year. Because remote sensing images are highly transient, the calculation results from single-phase remote sensing images have significant randomness and uncertainty. Furthermore, in the northern plains of my country, winter wheat is harvested in October, at which time the ecological environment assessment results are very low, but winter wheat exhibits higher ecological environment quality levels during other phenological periods; therefore, the calculated results are unreliable. The automatic indicator fitting method proposed in this invention can use batch calculations of remote sensing images throughout the year to obtain the average value, resulting in more reliable results.
[0058] This invention addresses the challenge of finding stochastic, bidirectional equivalent solutions in principal component analysis (PCA) during the weight allocation process. Through an innovative Flag indicator-oriented anchoring mechanism, it achieves a core breakthrough in PCA indicator fitting, transforming it from "random and uncontrollable" to "precise and traceable." Its beneficial effects are reflected in the following key dimensions:
[0059] Firstly, it overcomes technical bottlenecks to ensure the consistency and stability of weight allocation. This invention constructs a precise benchmark for judging the direction of feature vectors by screening Flag indicators that have a clear and significant impact on the dependent variable. This fundamentally avoids the ambiguous results of equal weights but opposite directions that occur during the random iteration of PCA. It completely solves the industry pain point that traditional PCA cannot perform batch automated calculations due to the uncertainty of weights. This allows each indicator component corresponding to the principal component feature vector to be stably used as fitting weights, providing core technical support for the standardization and streamlining of subsequent data processing. It significantly improves the reliability and engineering practicality of the PCA method in indicator fitting scenarios.
[0060] Secondly, it enables automated upgrades, improving fitting efficiency and scalable application capabilities. This invention, through the directional constraint of the Flag index, achieves automatic judgment and autonomous calibration of weight magnitude and direction during PCA index fitting, eliminating the need for manual intervention in the screening and correction of weight ambiguities. This significantly reduces the reliance on manual intervention in index fitting, substantially improves computational efficiency, and makes batch index fitting on large-scale datasets possible. It effectively expands the scalable application boundaries of the PCA method in scenarios such as automated data analysis and intelligent decision support, providing an efficient technical path for data-driven accurate modeling.
[0061] Third, it enhances generalization and adaptability, expanding the application scenarios and scope of the technology. The Flag index selection mechanism of this invention has extremely high flexibility and adaptability. It can dynamically determine the core anchor index according to the characteristics of different fields and different dependent variables. It can adapt to different scenarios without making disruptive modifications to the core PCA algorithm. It can be widely applied to the index fitting needs of multiple fields such as economic forecasting, environmental monitoring, medical diagnosis, and industrial quality control. It significantly improves the generalization ability and scenario adaptability of PCA technology, breaking through the application bottleneck of traditional PCA in specific scenarios due to unstable weights.
[0062] This study focuses on remote sensing ecological environment quality assessment. High-quality Landsat 8 remote sensing images of Pingyu County, Henan Province, from different seasons in 2025 were selected. Four remote sensing ecological indicators—NDVI, WET, LST, and NDBSI—were used for quantitative inversion, and a comprehensive regional ecological environment quality index was constructed based on principal component analysis (PCA). The study images were taken on March 10, August 17, and November 21, 2025. First, the traditional PCA model was used for calculation, and the results are shown in Figure 1 and Table 1. The contribution rate of the first principal component (PC1) eigenvalues in all three images exceeded 90%, indicating sufficient information carrying capacity for ecological assessment calculations. Therefore, only the first principal component was used for analysis. As shown in Figure 1, the data from March 10, August 17, and November 21 all exhibited a characteristic where the overall ecological quality of cultivated land was better than that of urban land. Based on field phenological analysis, in March, the main crop in Pingyu County was winter wheat, which was in the heading stage, with good vegetation growth and high ecological quality. In August, the main crop was summer corn, which was in the flowering stage, and the vegetation cover was also excellent. This phenological characteristic contradicts the output of the traditional PCA model. In November, due to continuous rainfall, the summer corn harvest was completed, but the winter wheat had not yet emerged, leaving large areas of farmland bare and significantly reducing ecological quality. Meanwhile, the green vegetation in urban areas continued to provide ecological benefits, causing the ecological quality of urban areas to surpass that of farmland. This pattern is consistent with the calculation results of the traditional model.
[0063] As shown in Table 1, in the traditional PCA model, the eigenvectors of the four indicators NDVI, WET, LST, and NDBSI in the first principal component of the data from March 10 and August 17 are negative, negative, positive, and positive, respectively; while the eigenvectors of the four indicators in November 21 are positive, positive, negative, and negative.
[0064]
[0065] The method proposed in this invention was used to recalculate the NDVI, which has a significant positive impact on the ecological environment. Therefore, NDVI was used as the Flag indicator, and the calculation results are shown in Figure 2 and Table 2.
[0066]
[0067] In the first principal component of the optimized model, the eigenvectors of the four indicators NDVI, WET, LST, and NDBSI are uniformly positive, positive, negative, and negative, respectively, and the evaluation results are completely consistent with the actual phenology, land cover, and ecological conditions of the region.
[0068] In the description of this invention, it should be noted that for directional terms, such as "center," "lateral," and "vertical," the appropriate terms may be used.
[0069] The directions and positional relationships indicated by symbols such as "direction", "length", "width", "thickness", "up", "down", "front", "back", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", "clockwise", and "counterclockwise" are based on the directions or positional relationships shown in the accompanying drawings and are only for the convenience of describing the present invention and simplifying the description. They are not intended to indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and should not be construed as limiting the specific protection scope of the present invention.
[0070] It should be noted that the terms "comprising" and "having" and any variations thereof in the specification and claims of this application are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not necessarily limited to those steps or units that are explicitly listed, but may include other steps or units that are not explicitly listed or that are inherent to such process, method, product, or device.
[0071] Note that the above description is merely a preferred embodiment and application of the technical principles of the present invention. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions can be made without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the specific embodiments described herein, and may include many other effective embodiments without departing from the concept of the present invention. The scope of the present invention is determined by the scope of the appended claims.
Claims
1. An automatic index fitting method based on principal component analysis, characterized in that: Includes the following steps: Step 1: Characteristic Vector Direction Judgment: Based on expert experience or relevant analysis methods, select indicators with clear and significant influence directions from the indicator system affecting the dependent variable y as Flag indicators. In each principal component analysis (PCA) operation, the direction of the characteristic vectors of each principal component is judged according to the direction of the Flag indicators, so that the indicator components corresponding to the characteristic vectors of each principal component can be stably used as fitting weights. Step 2: Adaptive screening of cumulative contribution rate of principal component eigenvalues: Based on the cumulative contribution rate threshold N set according to research needs, adaptively select the number m of principal components to participate in the fitting, so that the cumulative contribution rate of the eigenvalues of the first m principal components is not lower than the threshold N. Step 3: Automatic model fitting of the index: Based on the determined number of principal components m and the Flag index, the index fitting result Result is automatically obtained.
2. The automatic index fitting method based on principal component analysis according to claim 1, characterized in that, Step 1 specifically includes: S1.1 Setting Indicators ,…, For a system of indicators influencing a dependent variable y, based on expert experience and / or relevant analysis methods, identify the Flag indicator that has the most significant impact on the dependent variable y and whose direction of influence is clearly defined. This Flag indicator is denoted as... , where 1≤i≤n, and record whether its influence on the dependent variable y is positive or negative; S1.2 Inversion Indicators ,…, The original index matrix U is formed. ; S1.3 standardizes each index in the original matrix. The standardization formula is as follows: In the formula, for Indicator pixels exist The dimensionless result of time; Refers to the pixel exist At any moment The raw data for the indicator; and It is an indicator Maximum and minimum values under all spatiotemporal conditions; The standardized matrix is, ; S1.4 Based on standardized data, the correlation coefficient matrix R between indicators is calculated, and the correlation coefficient matrix is decomposed to obtain eigenvalues and eigenvectors, where: The eigenvector is denoted as : , ,… … , The contribution rate of eigenvalues is denoted as... ; The eigenvector is denoted as : , ,… … , The contribution rate of eigenvalues is denoted as... ; …… The eigenvector is denoted as : , ,… … , The contribution rate of eigenvalues is denoted as... .
3. The automatic index fitting method based on principal component analysis according to claim 2, characterized in that, Step (2) specifically includes: Based on research needs, a cumulative contribution rate threshold N is set, and the principal components obtained from a single principal component calculation are defined as follows: , …, The corresponding eigenvalue contribution rates are respectively , …, The corresponding feature vectors are respectively , …, According to research requirements, the cumulative contribution rate must be ≥ N, then: (1) In the formula, , …, N represents the contribution rate of the eigenvalues corresponding to each principal component in the principal component operation, and N is the minimum cumulative contribution rate that needs to be satisfied in practical applications.
4. The automatic index fitting method based on principal component analysis according to claim 3, characterized in that, The specific steps (3) are as follows: include: Let the eigenvectors be... The corresponding indicator components are respectively Then there is a Flag indicator. In the eigenvector The components in are Based on the Flag indicators determined in the previous steps Given the number of principal components m, where 1 ≤ m ≤ n, construct an auto-fit principal component model: If Flag indicator As a positive index of the dependent variable y: (2) (3) If Flag indicator It is the negative index of the dependent variable y: (4) (5) In the formula, This is the result of fitting the first principal component. The fitting result for the nth principal component is... For the nth principal component, the index In the eigenvector The corresponding index component values are m, where m refers to the cumulative contribution rate of the first m principal components that satisfy the preset feature values. Result is the result of index fitting.
5. The automatic index fitting method based on principal component analysis according to claim 1, characterized in that, In step 1, the correlation analysis method includes expert scoring or Pearson correlation analysis.
6. The automatic index fitting method based on principal component analysis according to claim 1, characterized in that, In step 1, the influence direction of the Flag index includes positive and negative correlation, and the direction of the feature vector is uniformly corrected based on the direction of the Flag index in the subsequent principal component direction analysis.
7. A system for automatic index fitting based on principal component analysis, characterized in that, include: Eigenvector direction determination module: The eigenvector direction determination module is the core foundation for realizing automated model operation. Its core goal is to solve the automation bottleneck problem caused by the uncertainty of weights in traditional PCA. Adaptive screening module for cumulative contribution rate of principal component eigenvalues: Based on actual research needs, adaptively determine the number of principal components participating in the fitting of subsequent indicators to ensure a balance between the explanatory power and simplification of the fitted model; Automatic indicator fitting module: Based on the output results of the first two modules, it completes the automatic fitting of indicators.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it causes the device containing the computer-readable storage medium to perform the automatic index fitting method based on principal component analysis as described in any one of claims 1-6.
9. An electronic device, characterized in that, include: A memory and a processor, wherein the memory stores a program that can run on the processor, and the processor executes the program to implement the automatic index fitting method based on principal component analysis as described in any one of claims 1-6.