A kind of data leveling method, electronic equipment and storage medium summarizing table
Technical field
The present invention relates to land investigation database Area summing statistics field more particularly to a kind of data tune for summarizing table
Quadratic method, electronic equipment and storage medium.
Background technique
Currently, the main task of national land investigation includes: rural holding investigation, investigate thoroughly the ground class in every block of soil, position,
Situations such as range, area distributions and ownership;Urban land investigation, grasps boundary location, range, boundary line, quantity and the use in every soil
On the way;Basic farmland investigation, basic farmland protection plot (block) is implemented on present landuse map, and is registered and demonstrate,proved, makes
Volume;Land Use Database and cadastral information system are established, realizes the interconnectivity and sharing of survey information.On the basis of investigation, build
Statistics, monitoring and the quick update mechanism of vertical land resource change information.Wherein, to county land investigation database into
Row achievement gathering before table, should statistically investigate database achievement, and data should meet database figure areal calculation and want
It asks, county area under one's jurisdiction control area calculates requirement, area statistics logic basic demand at different levels.For basic statistical table, adjusted using pressure
Flat method, township, at village level region area control on, using directly by county area under one's jurisdiction area control at village level, township level face
From at village level control area of the product again after leveling summarizes, and leveling difference is shared from big to small according to village's area,
Side leveling is taken, the mode summarized longitudinally upward shares leveling value to maximum value in side leveling.
But the existing method that basic statistical table is leveled using pressure, divided from big to small according to village's area
The mode at booth, it is possible to which difference will be leveled by, which causing, all shares in the same township level unit area, and then leads to township level control
Several errors is excessive, so that there are biggish errors between final township level control area aggregate value and exact value, especially in " third
Secondary whole nation land investigation technical regulation (consult on and do) " in, it is native compared with Second National to the ground class classification of land use data
It is more careful for ground investigation, if continuing to use the leveling method of second national land investigation, this mistake for summarizing generation step by step
Difference becomes apparent.
Summary of the invention
For overcome the deficiencies in the prior art, one of the objects of the present invention is to provide a kind of data leveling for summarizing table
Method, it can be ensured that the difference between value and its exact value after ground area leveling at different levels is in lesser range.
The second object of the present invention is to provide a kind of electronic equipment, it can be ensured that value after ground areas at different levels leveling with
Difference between its exact value is in lesser range.
The third object of the present invention is to provide a kind of storage medium, it can be ensured that value after ground areas at different levels leveling with
Difference between its exact value is in lesser range.
An object of the present invention adopts the following technical scheme that realization:
A kind of data leveling method summarizing table, comprising the following steps: basic statistical table splitting step: by basic statistical
Row and column in table is classified, and the primarily two-dimensional table of different stage is split as;First leveling step of first trip: to described basic two
Dimension table carries out first trip leveling, first leveling, and the control number for keeping the sum of first trip each unit lattice data corresponding is equal, first each list
The corresponding control number of the sum of first lattice data is equal;Internal leveling step line by line: using first each unit lattice data as control
Number, levels table inside line by line, keeps the sum of each unit lattice data of every row inside table equal with corresponding control number;
Internal combination column leveling step: using first trip each unit lattice data as control number, each column data in table inside is combined with two column
The mode for being formed together composite column levels, and keeps the sum of each unit lattice data of each column inside table equal with corresponding control number,
Meanwhile the sum of each unit lattice data of every row, primarily two-dimensional equal with first corresponding each unit lattice data inside table
Table is backfilling into the basic statistical table after leveling.
Further, it in the basic statistical table splitting step, is classified by the row and column to basic statistical table,
Column classification tree and row classification tree are formed, column classification tree and row classification tree is recycled to extract the primarily two-dimensional table of different stage.
Further, in first leveling step of the first trip, by calculating the deviation ratio of first trip each unit lattice data, knot
It closes leveling and needs to choose the smallest one or more cells progress data leveling of deviation ratio;By calculating first each unit lattice number
According to deviation ratio, need to choose the smallest one or more cells of deviation ratio in conjunction with leveling and carry out data leveling.
Further, in the inside line by line leveling step, pass through a line each unit lattice data every inside computation sheet
Deviation ratio, needed in conjunction with the leveling of row each inside table, choose the smallest one or more cells of deviation ratio and carry out data
Leveling.
Further, in the internal combination column leveling step, by calculating, respectively combination is single in each composite column
The combination deviation ratio of member, needs to choose the smallest assembled unit of deviation ratio in conjunction with leveling and is leveled;The assembled unit
For in the composite column be located at a line two cells, it is described combination deviation ratio be described two cells deviation ratio it
With.
Further, in the internal combination column leveling step, each column can form a variety of various combination sides inside table
The composite column set of formula, each composite column can be leveled by different order in the composite column set, so as to form multiple inside
Composite column leveling pass chooses the smallest leveling pass of overall offset rate by calculating the overall offset rate of each leveling pass
As optimal leveling pass, the overall offset rate be each leveling pass in all composite columns minimum combination deviation ratio it
With.
Further, the deviation ratio calculation formula is as follows
Wherein, x is the true value for retaining all mantissa before the revision of the convention, and ABS is to take absolute value, and x ", which is that true value x is corresponding, to be repaired
About it is worth.
Further, in the internal combination column leveling step, the sum of each unit lattice data are equal with corresponding control number
Column be not involved in internal combination column leveling.
The second object of the present invention adopts the following technical scheme that realization:
A kind of electronic equipment can be run on a memory and on a processor including memory, processor and storage
Computer program, the processor realize method described in one of the object of the invention when executing described program.
The third object of the present invention adopts the following technical scheme that realization:
A kind of computer readable storage medium, is stored thereon with computer program, and the computer program is held by processor
Method described in one of the object of the invention is realized when row.
Compared with prior art, the beneficial effects of the present invention are:
A kind of data leveling method, electronic equipment and storage medium summarizing table of the invention, by soils at different levels
Control area is summarized, then basic statistical table is split as to the basic bivariate table of different stage, to basic bivariate tables at different levels into
Row first trip first leveling, internal leveling line by line, internal combination column leveling, make data balancing in table, and data are consistent between table, then by base
The structure of this bivariate table is integrally substituted into basic statistical table, it is ensured that between the value and its exact value after ground area leveling at different levels
Difference in lesser range, convenient for the data statistics and analysis of land investigation.
Detailed description of the invention
Fig. 1 is a kind of flow diagram for the data leveling method for summarizing table of the present invention;
Fig. 2 is a kind of row classification tree for the data leveling method for summarizing table of the present invention, column classification tree schematic diagram;
Fig. 3 is that a kind of primarily two-dimensional at county level for the data leveling method for summarizing table of the present invention indicates to be intended to;
Fig. 4 is that a kind of primarily two-dimensional table for the data leveling method for summarizing table of the present invention levels schematic diagram;
Fig. 5 is a kind of optimal leveling pass schematic diagram of selection for the data leveling method for summarizing table of the present invention;
Specific embodiment
In the following, being described further in conjunction with attached drawing and specific embodiment to the present invention, it should be noted that not
Under the premise of conflicting, new implementation can be formed between various embodiments described below or between each technical characteristic in any combination
Example.
Embodiment one:
A kind of data leveling method summarizing table as shown in Figs. 1-5, comprising the following steps:
Basic statistical table splitting step: the row and column in basic statistical table is classified, and is split as the base of different stage
This bivariate table;Basic statistical table is all phases of basic worksheet that will be directly generated from second national land investigation database
Associated field summarizes the statistical form for covering all basic worksheet contents for one, in the base according to certain logical construction
In plinth statistical form splitting step, it then follows the row and column of basic statistical table is classified, is split as by the principle of data staging control
The basic table of different stage one by one, the minimum hierarchical table as table leveling.As shown in Fig. 2, by basic statistical table
Row and column be classified, form column classification tree and row classification tree, recycle column classification tree and row classification tree that can extract not
The primarily two-dimensional table of same level, Fig. 3 are the primarily two-dimensional table at county level extracted, which includes at county level
Control the contents such as number, state-owned land at county level, collective-owned land at county level.It should be noted that basic worksheet is converted into basic statistical
When table, the unit of basic statistical table is all converted to hectare, and data in table are carried out the revision of the convention, and rule for rounding off is using " four houses six
Enter five stay it is double " rule, all cell data retain 2 significant digits in table after the revision of the convention.
First leveling step of first trip: first trip leveling, first leveling are carried out to primarily two-dimensional tables at different levels, make first trip each unit lattice
The control number that number is equal for the corresponding control of the sum of data, the sum of first each unit lattice data are corresponding is equal.In first trip
In first leveling step, by calculating the deviation ratio of first trip each unit lattice data, need to choose deviation ratio in conjunction with leveling the smallest
One or more cells carry out data leveling;By calculating the deviation ratio of first each unit lattice data, need to select in conjunction with leveling
The smallest one or more cells of deviation ratio are taken to carry out data leveling.As shown in figure 4, in figure headed by " total " corresponding a line
Row, " total " corresponding one be classified as first, using the control area (unit is hectare) in the national administrative area under one's jurisdiction issued as first trip,
The gross area of first leveling controls number a, firstly, first trip each unit lattice data summarization in Fig. 4 is obtained aggregate value b, calculates control
The difference of number a and aggregate value b, obtain leveling number c, and leveling number c is to be leveled divided by rounding interval leveling unit (0.01)
Number d, wherein d is less than the half of row data recording number.Secondly, calculating separately the deviation ratio of each unit lattice, deviation ratio is the revision of the convention
It is the smallest to assign the value (0.01) of the leveling unit to deviation ratio for the degree of closeness of numerical value in primarily two-dimensional table and true value afterwards
One or several cells.For example, the difference of control number a and aggregate value b is 0.03, then leveling number is 3, therefore selects first trip
Middle the smallest three cells of deviation ratio are leveled, and are added 0.01 to the data of three cells respectively or are subtracted 0.01, make
The gross area that issues of the sum of final first trip each unit lattice data (the first trip aggregate value after leveling) and its country to control number poor
Value is 0.In addition, first the smallest cell of deviation ratio can also be selected to be leveled, the unit style according to leveling number 3
After flat, then the deviation ratio of first trip each unit lattice data is recalculated, chooses the smallest cell of deviation ratio and leveled, such as
This repeatedly for three times, until the sum of final first trip each unit lattice data (the first trip aggregate value after leveling) issued with its country it is total
Area control number difference is 0.First leveling mode is identical as first trip, does not repeat one by one here.It should be noted that deviation ratio
It is the degree of closeness of numerical value and true value after measuring the revision of the convention, the lower closer true value of deviation ratio, deviation ratio calculation formula
It is as follows
Wherein, x is the true value for retaining all mantissa before the revision of the convention, and ABS is to take absolute value, and x ", which is that true value x is corresponding, to be repaired
About it is worth.
Internal leveling step line by line: using first each unit lattice data as control number, leveling table inside line by line,
Keep the sum of each unit lattice data of every row inside table equal with corresponding control number.In internal leveling step line by line, pass through
The deviation ratio of every a line each unit lattice data inside computation sheet needs in conjunction with the leveling of row each inside table, chooses deviation ratio
The smallest one or more cell carries out data leveling.As shown in Fig. 4, first trip, the data within first (remove first in figure
Outside, the corresponding data of column heading 1-8) it is table internal data.The leveling method that levels line by line of inside it is practical with first trip first
Leveling method is identical, to complete the control of first each unit lattice data after first leveling step of first trip as every a line inside table
Number processed, for example, the difference of control number a and row aggregate value b is 0.02, then leveling number is 2, therefore selects deviation ratio in first trip
The smallest two cells are leveled, and are added 0.01 to the data of two cells respectively or are subtracted 0.01, so that finally
The sum of row each unit lattice data (the row land area aggregate value after leveling) and control number difference are 0.In addition, can also root
According to leveling number 2, first the smallest cell of deviation ratio is selected to be leveled, after cell leveling, then recalculates this
The deviation ratio of row each unit lattice data is chosen the smallest cell of deviation ratio and is leveled again, so that each list of the final row
The sum of first lattice data (the row land area aggregate value after leveling) and area control number difference are 0.It should be noted that warp
After crossing internal leveling line by line, first corresponding each unit of the sum of cell data of each row inside the table of primarily two-dimensional table
Lattice data are equal, still, the first trip each unit lattice data phase that the sum of the cell data respectively arranged inside table may not be corresponding
Deng, in order to not destroy the balance inside table between each row data and first data, while the unit for arranging table inside respectively
The corresponding first trip each unit lattice data of the sum of lattice data are equal, need to carry out internal combination column leveling step to table.
Internal combination column leveling step: using first trip each unit lattice data as control number, to each column data in table inside with
The mode that two column combinations are formed together composite column levels, and makes the sum of each unit lattice data of table inside each column and corresponding control
Number is equal, meanwhile, the sum of each unit lattice data of every row are equal with first corresponding each unit lattice data inside table, finally,
The primarily two-dimensional table is backfilling into basic statistical table after leveling.In internal composite column leveling step, by calculating each group
The combination deviation ratio for closing each assembled unit in column, needs to choose the smallest assembled unit of deviation ratio in conjunction with leveling and is adjusted
It is flat;Assembled unit is two cells being located in composite column with a line, and combination deviation ratio is the deviation ratio of two cells
The sum of.As shown in Fig. 4, using first trip each unit lattice data (data after first trip leveling is completed) as control number, A column in figure
Inner array difference (the corresponding cell data of A column first trip subtract the sum of each unit lattice data inside list lattice) be+0.01,
B column difference is -0.01, when internal combination column are leveled, can arrange A and B column are considered as a composite column, the column of AB two combination in figure
When, the corresponding two values of every a line are considered as an assembled unit, calculate separately a combination deviation ratio (group for each assembled unit
Close the sum of the deviation ratio of two cells in unit), the selection combination the smallest assembled unit of deviation ratio is leveled,
In, the inner array difference of A column is+0.01, the inner array for just adding 0.01, B to arrange in the cell data of assembled unit corresponding A column
Difference is -0.01, just subtracts 0.01 in the cell data that the assembled unit corresponds to B column.Pass through said combination column data data
Leveling, the inner array difference that A column, B are arranged are 0, meanwhile, which combines a line of the smallest assembled unit of deviation ratio, table
The sum of the internal row each unit lattice data are still equal with first corresponding cell data.It should be noted that for inside
Column difference is multiple leveling units, needs repeatedly to level, until need to being 0 by the column leveling value inner array difference.Such as Fig. 4 institute
Show, the inner array difference of C column is that 0.2, D is arranged, the inner array difference of F column is -0.1, then needing respectively to two groups of groups of CD, CF
It closes column to be leveled, leveling method is identical as composite column AB.And it is equal with corresponding control number for the sum of each unit lattice data
Column (F that such as inner array difference is 0 is arranged) are not involved in internal combination column leveling.It is arranged and is leveled by internal combination, number in table can be made
According to balance, data are consistent between table, and the structure of the primarily two-dimensional table is integrally substituted into basic statistical table, and it is basic that this can be completed
The leveling of bivariate table.In addition, each column can form a variety of various combination modes inside table in internal composite column leveling step
Composite column set, each composite column can be leveled by different order in composite column set, arranged and adjusted so as to form multiple internal combinations
Level road diameter chooses the smallest leveling pass of overall offset rate as optimal by calculating the overall offset rate of each leveling pass
Leveling pass, overall offset rate are the sum of the minimum combination deviation ratio of all composite columns in each leveling pass.It is shown in Fig. 4
Primarily two-dimensional table internal combination column leveling in, just like a variety of leveling approach shown in fig. 5, in Fig. 5, each column combination is considered as
One independent pathway, each composite column are considered as a node in path, and R1-R6 indicates the corresponding overall offset rate of each column,
Numerical value is equal to the sum of the combination deviation ratio of each node in the path.Taking the corresponding independent pathway of minimum value in R1-R6 is optimal road
Diameter.If then taking the smallest path of number is optimal road it should be noted that the minimum value of combination the sum of deviation ratio has multiple
Diameter guarantees the uniqueness of leveling result.After determining optimal path, to the assembled unit in requisition for adjustment in each composite column of table
It has been fixed that, the leveling of entire primarily two-dimensional table is can be completed into corresponding unit lattice in+0.01 and -0.01 revision of the convention respectively.
The basic two-dimentional of different stage is split as by summarizing to land control areas at different levels, then by basic statistical table
Table levels first leveling of basic bivariate tables progress first trip at different levels, internal leveling line by line, internal combination column, keeps data in table flat
It weighs, data are consistent between table, then the structure of primarily two-dimensional table is integrally substituted into basic statistical table, that is, can ensure that ground at different levels class face
The difference between value and its exact value after product leveling is in lesser range, convenient for the data statistics and analysis of land investigation.
Embodiment two:
Embodiment two discloses a kind of electronic equipment, including memory, processor and storage are on a memory and can be
The computer program run on processor, the processor realize a kind of number for summarizing table of embodiment one when executing described program
According to leveling method.Wherein, one or more can be used in processor and memory, and program is stored in memory, and by
It is configured to be executed by processor, which can be a series of electronic equipment of computer, tablet computer etc..
Embodiment three:
Embodiment three discloses a kind of readable computer storage medium, which is somebody's turn to do for storing program
When program is executed by processor, a kind of data leveling method for summarizing table of embodiment one is realized
The above embodiment is only the preferred embodiment of the present invention, and the scope of protection of the present invention is not limited thereto,
The variation and replacement for any unsubstantiality that those skilled in the art is done on the basis of the present invention belong to institute of the present invention
Claimed range.