A projection method from column chart to geographic map

By calculating and projecting the parameter information of the bar chart, the problem of the traditional bar chart and the geographical map coordinate system is solved, and the accurate projection and drawing of the bar chart on the geographical map is realized, simplifying the operation and release process.

CN115063289BActive Publication Date: 2025-04-25NAT MARINE DATA & INFORMATION SERVICE
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210625845.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-02
Publication Date
2025-04-25
Estimated Expiration
2042-06-02

AI Technical Summary

Technical Problem

The traditional bar chart is separated from the coordinate system of the geographical map, causing the graphic position to change when the map scale is switched, affecting operations and post-release.

Method used

By determining the parameter information of the latitude and longitude regions and histograms, the basic information of the projection model and the coordinates of the histogram drawing borders are calculated, and then the histogram is projected to the geographical map to ensure that the figure is stable when the scale is switched.

Benefits of technology

It realizes accurate projection and drawing of histograms and geographic maps, solves the problem of graphic position changes, and simplifies the operation and release process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115063289B_ABST
    Figure CN115063289B_ABST
Patent Text Reader

Abstract

The present invention provides a projection method of a bar chart to a geographic map, comprising the following steps: determining the latitude and longitude square area parameter information and bar chart parameter information in the geographic map to be input; determining the basic information of the projection model; calculating the drawing frame coordinates; calculating the projected bar chart coordinates; calculating the scale of the Y axis; calculating the X axis and Y axis labels; and outputting the calculation results. The present invention can project the values ​​of each element based on the latitude and longitude square area statistics to the geographic map, and further directly draw them into the statistical grid of the geographic map, and can be widely used in the production of GIS thematic maps.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of map projection calculation, and in particular to a projection method of a bar graph to a geographic map. Background Art

[0002] Traditional atlases can fully display the distribution of multiple elements. Multi-element bar charts based on longitude and latitude area statistics show the distribution of each element over a period of time, which is an important type of atlas. In the traditional production process, this kind of bar chart is made by manual overlay, which is time-consuming and laborious. Although the thematic map drawing by GIS software can realize the automatic drawing of bar charts, its bar charts are separated from the geographic map coordinate system. When the map scale is switched, the position of the graphics will change, and there are many obstacles in the operation and publication of graphics.

[0003] Therefore, how to provide a projection calculation method for a bar graph to a geographic map is a problem that those skilled in the art need to solve urgently. Summary of the invention

[0004] In view of this, the present invention projects the element bar chart based on longitude and latitude area statistics onto the geographic map to solve the problem of bar chart operation and map post-release caused by map scale switching. The present invention can be used as a reference method for big data dimensionality reduction visualization.

[0005] In order to achieve the above object, the present invention adopts the following technical solution:

[0006] The present invention discloses a projection method of a histogram to a geographical map, comprising the following steps:

[0007] Determine the latitude and longitude square area parameter information and bar chart parameter information in the geographic map to be input: the latitude and longitude square area parameter information includes: the latitude and longitude of the lower left corner of the latitude and longitude square area lon, lat, the latitude and longitude square area size gridsize; the bar chart parameter information includes: the Y-axis scale sequence level, the bar chart sequence z; the number of z values ​​is nz, and the number of levels is nv;

[0008] Determine the basic information of the projection model: the distance ratios between the longitude and latitude square area and the four sides of the bar chart drawing border, leftScale, rightScale, topScale, bottomScale, and the ratio of the Y-axis scale of the bar chart to the size of the longitude and latitude square area, ytickScale;

[0009] The coordinates of the bar chart drawing frame in the geographic map are obtained according to the latitude and longitude square area parameter information and the ratio of the four corner blanks to the latitude and longitude square area size, including the coordinates of the lower left corner starting point;

[0010] The four-corner coordinates of each column area in the histogram in the geographic map are obtained according to the coordinates of the lower left corner starting point of the drawing frame, the histogram parameter information and the ratio of the four-corner blanks to the size of the longitude and latitude square area.

[0011] Preferably, the step of projecting to obtain the coordinates of the bar graph drawing frame includes:

[0012] Based on the longitude lon of the lower left corner, the size of the longitude and latitude area gridsize, and the ratios of the left and bottom borders of the bar chart drawing border to the size of the longitude and latitude area leftScale and bottomScale, calculate the starting point coordinates (x, y) of the lower left corner of the drawing border;

[0013] Calculate the coordinates of the lower right corner of the drawing border based on the coordinates x of the lower left corner of the drawing border, the size of the longitude and latitude area gridsize, and the ratios of the left and right borders of the bar chart drawing border to the size of the longitude and latitude area leftScale and rightScale;

[0014] The coordinates of the upper left corner of the drawing border are calculated based on the coordinate y of the lower left corner starting point of the drawing border, the size of the longitude and latitude square area gridsize, and the ratios of the upper and lower borders of the bar chart drawing border to the size of the longitude and latitude square area topScale and bottomScale.

[0015] Preferably, the step of projecting to obtain the four-corner coordinates of each columnar area in the histogram includes:

[0016] Calculate the maximum value of the Y-axis scale sequence level;

[0017] Based on the number of z values ​​nz and the ratio of the left and right borders of the bar chart drawing border to the size of the longitude and latitude square area, leftScale and rightScale, the ratio of the X-axis length occupied by the calculated column area m is calculated;

[0018] Based on the maximum value of the Y-axis scale sequence level and the ratio of the upper and lower borders of the bar chart drawing border to the size of the longitude and latitude square area, topScale and bottomScale, the ratio of the Y-axis length occupied by the calculated column area m is calculated;

[0019] Based on the ratio of the length of the x-axis and the length of the y-axis occupied by the cylindrical area m, the coordinates of the four corners of the cylindrical area m are calculated in combination with the coordinates (x, y) of the starting point of the lower left corner of the drawing frame and the latitude and longitude square size gridsize.

[0020] Preferably, the method further includes the step of projecting to obtain the coordinate starting point and end point of the Y-axis scale of the bar graph drawing frame in the geographic map:

[0021] Based on the starting point coordinate y of the lower left corner of the drawing frame, the Y-axis scale sequence level, the Y-axis length ratio of the column area m, and the longitude and latitude square area size gridsize, the Y-axis direction coordinate yt of the Y-axis scale short line is obtained;

[0022] Based on the starting coordinate x of the lower left corner of the drawing border, the ratio ytickScale of the Y-axis scale of the bar chart to the size of the longitude and latitude square area, and the projection of the longitude and latitude square area gridsize, the starting point xt1 and the end point xt2 of the Y-axis scale short line in the X-axis direction are obtained.

[0023] Preferably, the basic information of the projection model further includes: the ratio xlabScale and ylabScale of the XY coordinate axis annotation relative to the size of the square area; and the step of projecting to obtain the coordinates of the X-axis annotation and the Y-axis annotation of the bar chart drawing frame in the geographic map:

[0024] Steps for projecting coordinates on the X-axis in a geographic map:

[0025] The y coordinate of the X-axis label is obtained based on the coordinate y of the lower left corner of the drawing frame, the ratio xlabScale of the XY axis label relative to the size of the square area, and the latitude and longitude square area size gridsize;

[0026] Based on the coordinate x of the lower left corner of the drawing frame, the ratio of the X-axis length occupied by the cylindrical area m, and the latitude and longitude square area size gridsize projection, the x-coordinate of the X-axis label of the cylindrical area m corresponding to the scale is obtained;

[0027] Steps for projecting coordinates on the Y-axis in a geographic map:

[0028] The y coordinate of the Y axis label is obtained based on the coordinate y of the lower left corner of the drawing frame, the ratio of the Y axis length occupied by the cylindrical area m, the Y axis scale sequence level, and the latitude and longitude square area size gridsize;

[0029] Based on the coordinate x of the lower left corner starting point of the drawing border, the ratio of the XY coordinate axis label to the square area size ylabScale, the ratio of the Y axis scale of the bar chart to the longitude and latitude square area size ytickScale and the longitude and latitude square area size gridsize, the x coordinate of the Y axis label of the corresponding scale of the column area m is projected.

[0030] Preferably, the basic information of the projection model further includes: the ratio xlabScale and ylabScale of the XY coordinate axis marking relative to the size of the square area; and the step of projecting to obtain the coordinates of the Y axis measurement unit marked on the geographic map:

[0031] Calculate the y coordinate of the Y-axis measurement unit based on the starting point coordinate y of the lower left corner of the drawing border, the ratio of the Y-axis length occupied by the column area m, the Y-axis scale sequence level, the ratio of the Y-axis scale of the bar chart to the size of the longitude and latitude area ytickScale, and the longitude and latitude area size gridsize;

[0032] Based on the x coordinate of the lower left corner of the drawing border, the ratio of the XY axis label to the square size ylabScale, the ratio of the Y axis scale of the bar chart to the longitude and latitude square size ytickScale, and the longitude and latitude square size gridsize, calculate the x coordinate of the Y axis measurement unit.

[0033] Preferably, the method further comprises the step of outputting the calculation result:

[0034] Connect the coordinates of the bar chart drawing border in the geographic map and output it as a line file;

[0035] Connect the four corner coordinates of each column area in the bar chart in the geographic map to generate a bar chart surface and output it as a surface file.

[0036] Preferably, the method further includes the step of outputting the calculation results: connecting the coordinate starting point and end point of the Y-axis scale of the bar chart drawing frame in the geographic map, and outputting the result as a line file.

[0037] Preferably, the method further includes the step of outputting the calculation results: outputting the coordinates of the X-axis labeling and the Y-axis labeling of the bar chart drawing frame in the geographic map respectively, and outputting them as a point file.

[0038] It can be seen from the above technical solution that, compared with the prior art, the beneficial effects of the present invention include:

[0039] The present invention can project the values ​​of various elements based on longitude and latitude area statistics onto a geographic map, and further directly draw them into the statistical grid of the geographic map, and can be widely used in the production of GIS thematic maps. Specifically, the present invention has the following advantages:

[0040] 1. The steps of the present invention are clear, the calculation is simple, and it is easy to implement: the present invention starts from inputting calculation parameters → setting basic information, including setting the four corner ranges of the projected figure, setting the Y-axis scale size ratio, setting the XY-axis annotation position ratio → calculating the drawing frame coordinates → calculating the projected bar chart coordinates → calculating the Y-axis scale → calculating the X-axis and Y-axis annotations → outputting the calculation results. The operation steps are clear step by step, the calculation is simple, and it is easy to implement.

[0041] 2. The results of the present invention are clear and easy to apply, store and manage: The results of the present invention are clear, including 5 files, namely, drawing border line file, element column map file, Y-axis scale line file, X-axis annotation point file and Y-axis annotation point file, which are easy to symbolize, render and use in GIS software. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art are briefly introduced below. Obviously, the drawings in the following description are only embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on the provided drawings without creative work.

[0043] Figure 1 A flowchart of a method for projecting a bar graph onto a geographic map provided by an embodiment of the present invention;

[0044] Figure 2 The projection result of the bar graph to the geographical map provided by the embodiment of the present invention Figure 1 ;

[0045] Figure 3 The projection result of the bar graph to the geographical map provided by the embodiment of the present invention Figure 2 . DETAILED DESCRIPTION

[0046] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0047] The embodiment of the present invention discloses a method for projecting a bar graph onto a geographic map. Figure 1 , the specific steps are as follows:

[0048] S1. Determine the latitude and longitude square area parameter information and the bar chart parameter information in the geographic map to be input: the latitude and longitude square area parameter information includes: the longitude and latitude of the lower left corner of the latitude and longitude square area lon, lat, and the latitude and longitude square area size gridsize; the bar chart parameter information includes: the Y-axis scale sequence level, the bar chart sequence z; the number of z values ​​is nz, and the number of levels is nv.

[0049] In this step, the calculation parameters input also include the bar chart series name colname and the Y-axis unit yStr.

[0050] S2. Determine the basic information of the projection model: the distance ratios between the longitude and latitude square area and the four sides of the bar chart drawing border, namely leftScale, rightScale, topScale, and bottomScale, and the ratio ytickScale of the Y-axis scale of the bar chart relative to the size of the longitude and latitude square area.

[0051] In this step, after repeated calculations, the values ​​of each parameter are as follows:

[0052] leftScale=0.15

[0053] rightScale=0.10

[0054] topScale=0.1

[0055] bottomScale=0.10

[0056] ytickScale=0.015

[0057] xylabScale=0.03

[0058] Among them, leftScale is the distance ratio of the left side of the bar graph drawing border to the left side of the longitude and latitude area; rightScale is the distance ratio of the right side of the bar graph drawing border to the right side of the longitude and latitude area; topScale is the distance ratio of the upper side of the bar graph drawing border to the upper edge of the longitude and latitude area; bottomScale is the distance ratio of the lower side of the bar graph drawing border to the lower edge of the longitude and latitude area. These basic information are relatively reasonable and beautiful relative position parameters obtained through multiple calculations.

[0059] S3. The coordinates of the bar chart drawing frame in the geographic map are obtained according to the latitude and longitude square area parameter information and the ratio of the four corner blanks to the latitude and longitude square area size, including the coordinates of the lower left corner starting point.

[0060] In one embodiment, the step of projecting the coordinates of the bar graph drawing frame includes:

[0061] Based on the longitude lon of the lower left corner, the size of the longitude and latitude area gridsize, and the ratios of the left and bottom borders of the bar chart drawing border to the size of the longitude and latitude area leftScale and bottomScale, calculate the starting point coordinates (x, y) of the lower left corner of the drawing border;

[0062] Calculate the coordinates of the lower right corner of the drawing border based on the coordinates x of the lower left corner of the drawing border, the size of the longitude and latitude area gridsize, and the ratios of the left and right borders of the bar chart drawing border to the size of the longitude and latitude area leftScale and rightScale;

[0063] The coordinates of the upper left corner of the drawing border are calculated based on the coordinate y of the lower left corner starting point of the drawing border, the size of the longitude and latitude square area gridsize, and the ratios of the upper and lower borders of the bar chart drawing border to the size of the longitude and latitude square area topScale and bottomScale.

[0064] The specific implementation process is as follows:

[0065] Calculate the lower left corner starting point:

[0066] x=lon+gridsize*leftscale;

[0067] y=lat+gridsize*bottomscale;

[0068] Calculate the maximum value on the right side of the histogram X:

[0069] xend=x+gridsize*(1-leftscale-rightscale)

[0070] Maximum value of Y top of histogram:

[0071] yend=y+gridsize*(1-topscale-bottomscale);

[0072] Therefore, the coordinates of the upper left corner are (x,yend), the coordinates of the lower left corner are (x,y), and the coordinates of the lower right corner are (xend,y).

[0073] S4. Obtain the four-corner coordinates of each column area in the histogram in the geographic map according to the coordinates of the lower left corner starting point of the drawing frame, the histogram parameter information and the ratio of the four-corner blanks to the size of the longitude and latitude square area.

[0074] In one embodiment, the step of projecting to obtain the four-corner coordinates of each columnar area in the histogram includes:

[0075] Calculate the maximum value of the Y-axis scale sequence level;

[0076] Based on the number of z values ​​nz and the ratio of the left and right borders of the bar chart drawing border to the size of the longitude and latitude square area, leftScale and rightScale, the ratio of the X-axis length occupied by the calculated column area m is calculated;

[0077] Based on the maximum value of the Y-axis scale sequence level and the ratio of the upper and lower borders of the bar chart drawing border to the size of the longitude and latitude square area, topScale and bottomScale, the ratio of the Y-axis length occupied by the calculated column area m is calculated;

[0078] Based on the ratio of the length of the x-axis and the length of the y-axis occupied by the cylindrical area m, the coordinates of the four corners of the cylindrical area m are calculated in combination with the coordinates (x, y) of the starting point of the lower left corner of the drawing frame and the latitude and longitude square size gridsize.

[0079] The specific implementation process is as follows:

[0080] Calculate the maximum value of the Y-axis scale level, that is, the highest scale value:

[0081] maxlev = max(level);

[0082] Calculate the x-axis distance ratio of each column:

[0083] xscale=(1-leftscale-rightscale) / nz;

[0084] The y-axis distance ratio corresponding to each column value:

[0085] yscale=(1-topscale-bottomscale) / maxlev;

[0086] The bottom coordinates of the mth column:

[0087] zymin=y;

[0088] The top coordinates of the mth column:

[0089] zymax=y+z(m)*yscale*gridsize;

[0090] z(m) represents the mth column area sequence, such as Figure 2 There are a total of 6 values ​​of z, m∈[1,6].

[0091] The left coordinate of the mth column:

[0092] zxmin=x+(m-1)*xscale*gridsize;

[0093] The right coordinate of the mth column:

[0094] zxmax=x+m*xscale*gridsize;

[0095] The coordinates of the four corners of the bar chart are the lower left corner (zxmin, zymin), the upper left corner (zxmin, zymax), the upper right corner (zxmax, zymax), and the lower right corner (zxmax, zymin). The column surface can be drawn according to the coordinates of the four corners.

[0096] Among them, m∈[1,nz].

[0097] In one embodiment, the step of projecting to obtain the coordinate starting point and end point of the Y-axis scale of the bar graph drawing frame in the geographic map is also included:

[0098] Based on the starting point coordinate y of the lower left corner of the drawing frame, the Y-axis scale sequence level, the Y-axis length ratio of the column area m, and the longitude and latitude square area size gridsize, the Y-axis direction coordinate yt of the Y-axis scale short line is obtained;

[0099] Based on the starting coordinate x of the lower left corner of the drawing border, the ratio ytickScale of the Y-axis scale of the bar chart to the size of the longitude and latitude square area, and the projection of the longitude and latitude square area gridsize, the starting point xt1 and the end point xt2 of the Y-axis scale short line in the X-axis direction are obtained.

[0100] The specific implementation process is as follows:

[0101] yt=y+level(m)*yscale*gridsize;

[0102] xt1=x-ytickscale*gridsize;

[0103] xt2=x;

[0104] The coordinate starting point of the Y-axis scale short line is (xt1, yt) and the end point is (xt2, yt).

[0105] Among them, m∈[1,nz].

[0106] In one embodiment, the basic information of the projection model further includes: the ratio xlabScale and ylabScale of the XY coordinate axis labels relative to the size of the square area; and the step of projecting to obtain the coordinates of the X-axis label and the Y-axis label of the bar chart drawing frame in the geographic map:

[0107] Steps for projecting coordinates on the X-axis in a geographic map:

[0108] The y coordinate of the X-axis label is obtained based on the coordinate y of the lower left corner of the drawing frame, the ratio xlabScale of the XY axis label relative to the size of the square area, and the latitude and longitude square area size gridsize;

[0109] Based on the coordinate x of the lower left corner of the drawing frame, the ratio of the X-axis length occupied by the cylindrical area m, and the latitude and longitude square area size gridsize projection, the x-coordinate of the X-axis label of the cylindrical area m corresponding to the scale is obtained;

[0110] Steps for projecting coordinates on the Y-axis in a geographic map:

[0111] The y coordinate of the Y axis label is obtained based on the coordinate y of the lower left corner of the drawing frame, the ratio of the Y axis length occupied by the cylindrical area m, the Y axis scale sequence level, and the latitude and longitude square area size gridsize;

[0112] Based on the coordinate x of the lower left corner starting point of the drawing border, the ratio of the XY coordinate axis label to the square area size ylabScale, the ratio of the Y axis scale of the bar chart to the longitude and latitude square area size ytickScale and the longitude and latitude square area size gridsize, the x coordinate of the Y axis label of the corresponding scale of the column area m is projected.

[0113] The specific implementation process is as follows:

[0114] Calculate the X-axis label:

[0115] The y coordinate of the x-axis: zty = y-xlabscale*gridsize;

[0116] The x coordinate of the mth scale: ztx=x+(m-0.5)*xscale*gridsize;

[0117] Calculate the Y axis label:

[0118] The y coordinate of the Y axis: zty = y + yscale*level(m)*gridsize;

[0119] Level(m) represents the y-axis scale corresponding to the m-th column area.

[0120] The x-coordinate of the Y-axis:

[0121] ztx=x-(ylabscale+ytickscale)*gridsize.

[0122] In one embodiment, the basic information of the projection model further includes: the ratio xlabScale and ylabScale of the XY coordinate axis labels relative to the size of the square area; and the step of projecting to obtain the coordinates of the Y axis measurement unit labeled in the geographic map:

[0123] Calculate the y coordinate of the Y-axis measurement unit based on the starting point coordinate y of the lower left corner of the drawing border, the ratio of the Y-axis length occupied by the column area m, the Y-axis scale sequence level, the ratio of the Y-axis scale of the bar chart to the size of the longitude and latitude area ytickScale, and the longitude and latitude area size gridsize;

[0124] Based on the x coordinate of the lower left corner of the drawing border, the ratio of the XY axis label to the square size ylabScale, the ratio of the Y axis scale of the bar chart to the longitude and latitude square size ytickScale, and the longitude and latitude square size gridsize, calculate the x coordinate of the Y axis measurement unit.

[0125] The specific implementation process is as follows:

[0126] The y coordinate of the Y-axis measurement unit: zty=y+yscale*level(m)*gridsize+ytickscale*gridsize;

[0127] Level(m) represents the y-axis scale corresponding to the m-th column area.

[0128] The x-coordinate of the Y-axis measurement unit:

[0129] ztx=x-(ylabscale+ytickscale)*gridsize;

[0130] Among them, m∈[1,nz].

[0131] In one embodiment, the step of outputting the calculation result is further included:

[0132] Connect the coordinates of the bar chart drawing border in the geographic map and output it as a line file;

[0133] Connect the four corner coordinates of each column area in the bar chart in the geographic map to generate a bar chart surface and output it as a surface file.

[0134] Connect the coordinates of the starting and ending points of the Y-axis scale of the bar chart drawing border in the geographic map and output them as a line file. Repeat this operation for each Y-axis scale.

[0135] Output the coordinates of the X-axis label and Y-axis label of the bar chart drawing frame in the geographic map respectively, and output them as point files.

[0136] The file format of the projection calculation results output realizes the classification and organization of the calculation results, making the calculation results more orderly and easy to carry out the next step of graphics drawing and rendering.

[0137] like Figure 2 As shown, this is a projection result effect diagram of the symbolization, rendering and use of the present invention in GIS software, which can project the value of each element based on the longitude and latitude area statistics to the geographic map, and further directly draw it into the statistical grid of the geographic map, which can be widely used in the production of GIS thematic maps.

[0138] As shown in Table 1, the geographical map projection data of 6 series of bar charts under 13 sets of longitude and latitude:

[0139] longitude latitude Sequence 1 Sequence 2 Sequence 3 Sequence 4 Sequence 5 Sequence 6 117 23 8 3 5 3 19 13 119 23 10 6 3 6 20 23 113 21 10 9 3 6 20 14 115 21 9 3 14 4 17 14 117 21 10 21 10 2 8 3 119 21 14 12 18 5 7 6 121 21 10 9 3 6 20 14 111 19 10 9 3 6 20 14 113 19 8 3 5 21 8 3 115 19 15 12 9 14 3 5 117 19 14 12 18 5 7 6 119 19 15 12 9 14 3 5 121 19 9 5 3 9 15 4

[0140] like Figure 3 As shown, the projection effect diagram of the above 6 series of bar charts on 13 groups of longitude and latitude on the geographical map.

[0141] The above is a detailed introduction to the projection method of the bar chart to the geographic map provided by the present invention. In this embodiment, specific examples are used to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea; at the same time, for those skilled in the art, according to the idea of ​​the present invention, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.

[0142] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined in the present embodiments may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown in the present embodiment, but will conform to the widest range consistent with the principles and novel features disclosed in the present embodiment.

Claims

1. A method for projecting a bar graph onto a geographic map, characterized in that: The steps include: Determine the latitude and longitude square area parameter information and bar chart parameter information in the geographic map to be input: the latitude and longitude square area parameter information includes: the latitude and longitude of the lower left corner of the latitude and longitude square area lon, lat, the latitude and longitude square area size gridsize; the bar chart parameter information includes: the Y-axis scale sequence level, the bar chart sequence z; the number of z values ​​is nz, and the number of levels is nv; Determine the basic information of the projection model: the distance ratios between the longitude and latitude square area and the four sides of the bar chart drawing border, leftScale, rightScale, topScale, bottomScale, and the ratio of the Y-axis scale of the bar chart to the size of the longitude and latitude square area, ytickScale; The coordinates of the bar chart drawing frame in the geographic map are obtained according to the latitude and longitude square area parameter information and the ratio of the four corner blanks to the latitude and longitude square area size, including the coordinates of the lower left corner starting point; The four-corner coordinates of each column area in the histogram in the geographic map are obtained according to the coordinates of the lower left corner starting point of the drawing frame, the histogram parameter information and the ratio of the four-corner blanks to the size of the longitude and latitude square area.

2. The method for projecting a bar graph onto a geographic map according to claim 1, characterized in that: The steps of projecting the coordinates of the bar chart drawing border include: Based on the longitude lon of the lower left corner, the size of the longitude and latitude area gridsize, and the ratio of the left and bottom borders of the bar chart drawing border to the size of the longitude and latitude area leftScale, bottomScale, calculate the starting point coordinates (x, y) of the lower left corner of the drawing border; Calculate the coordinates of the lower right corner of the drawing border based on the coordinates x of the lower left corner of the drawing border, the size of the longitude and latitude area gridsize, and the ratios of the left and right borders of the bar chart drawing border to the size of the longitude and latitude area leftScale and rightScale; The coordinates of the upper left corner of the drawing border are calculated based on the coordinate y of the lower left corner starting point of the drawing border, the size of the longitude and latitude square area gridsize, and the ratios of the upper and lower borders of the bar chart drawing border to the size of the longitude and latitude square area topScale and bottomScale.

3. The method for projecting a bar graph onto a geographic map according to claim 1, characterized in that: The steps of projecting and obtaining the four-corner coordinates of each column area in the histogram include: Calculate the maximum value of the Y-axis scale sequence level; Based on the number of z values ​​nz and the ratio of the left and right borders of the bar chart drawing border to the size of the longitude and latitude square area, leftScale and rightScale, the ratio of the X-axis length occupied by the calculated column area m is calculated; Based on the maximum value of the Y-axis scale sequence level and the ratio of the upper and lower borders of the bar chart drawing border to the size of the longitude and latitude square area, topScale and bottomScale, the ratio of the Y-axis length occupied by the calculated column area m is calculated; Based on the ratio of the length of the x-axis and the length of the y-axis occupied by the cylindrical area m, the coordinates of the four corners of the cylindrical area m are calculated in combination with the coordinates (x, y) of the starting point of the lower left corner of the drawing frame and the latitude and longitude square size gridsize.

4. The method for projecting a bar graph onto a geographic map according to claim 3, characterized in that: It also includes the steps of projecting the coordinate starting point and end point of the Y-axis scale of the bar chart drawing frame in the geographic map: Based on the starting point coordinate y of the lower left corner of the drawing frame, the Y-axis scale sequence level, the Y-axis length ratio of the column area m, and the longitude and latitude square area size gridsize, the Y-axis direction coordinate yt of the Y-axis scale short line is obtained; Based on the starting coordinate x of the lower left corner of the drawing border, the ratio ytickScale of the Y-axis scale of the bar chart to the size of the longitude and latitude square area, and the projection of the longitude and latitude square area gridsize, the starting point xt1 and the end point xt2 of the Y-axis scale short line in the X-axis direction are obtained.

5. The method for projecting a bar graph onto a geographic map according to claim 3, characterized in that: The basic information of the projection model also includes: the ratio xlabScale and ylabScale of the XY coordinate axis annotation relative to the size of the square area; and the step of projecting to obtain the coordinates of the X-axis annotation and the Y-axis annotation of the bar chart drawing frame in the geographic map: Steps for projecting coordinates on the X-axis in a geographic map: The y coordinate of the X-axis label is obtained based on the coordinate y of the lower left corner of the drawing frame, the ratio xlabScale of the XY axis label relative to the size of the square area, and the latitude and longitude square area size gridsize; Based on the coordinate x of the lower left corner of the drawing frame, the ratio of the X-axis length occupied by the cylindrical area m, and the latitude and longitude square area size gridsize projection, the x-coordinate of the X-axis label of the cylindrical area m corresponding to the scale is obtained; Steps for projecting coordinates on the Y-axis in a geographic map: The y coordinate of the Y axis label is obtained based on the coordinate y of the lower left corner of the drawing frame, the ratio of the Y axis length occupied by the cylindrical area m, the Y axis scale sequence level, and the latitude and longitude square area size gridsize; Based on the coordinate x of the lower left corner starting point of the drawing border, the ratio of the XY coordinate axis label to the square area size ylabScale, the ratio of the Y axis scale of the bar chart to the longitude and latitude square area size ytickScale and the longitude and latitude square area size gridsize, the x coordinate of the Y axis label of the corresponding scale of the column area m is projected.

6. The method for projecting a bar graph onto a geographic map according to claim 3, characterized in that: The basic information of the projection model also includes: the ratio xlabScale and ylabScale of the XY coordinate axis annotation relative to the size of the square area; and the step of projecting to obtain the coordinates of the Y axis measurement unit annotation in the geographic map: Calculate the y coordinate of the Y-axis measurement unit based on the starting point coordinate y of the lower left corner of the drawing border, the ratio of the Y-axis length occupied by the column area m, the Y-axis scale sequence level, the ratio of the Y-axis scale of the bar chart to the size of the longitude and latitude area ytickScale, and the longitude and latitude area size gridsize; Based on the x coordinate of the lower left corner of the drawing border, the ratio of the XY axis label to the square size ylabScale, the ratio of the Y axis scale of the bar chart to the longitude and latitude square size ytickScale, and the longitude and latitude square size gridsize, calculate the x coordinate of the Y axis measurement unit.

7. The method for projecting a bar graph onto a geographic map according to claim 1, characterized in that: It also includes the steps of outputting the calculation results: Connect the coordinates of the bar chart drawing border in the geographic map and output it as a line file; Connect the four corner coordinates of each column area in the bar chart in the geographic map to generate a bar chart surface and output it as a surface file.

8. The method for projecting a bar graph onto a geographic map according to claim 4, characterized in that: The step of outputting the calculation results is also included: connecting the coordinate starting point and end point of the Y-axis scale of the bar chart drawing border in the geographic map, and outputting them as a line file.

9. The method for projecting a bar graph onto a geographic map according to claim 5, characterized in that: The step of outputting the calculation results is also included: outputting the coordinates of the X-axis label and the Y-axis label of the bar chart drawing frame in the geographic map respectively, and outputting them as a point file.

Citation Information

Patent Citations

  • Projection calculation method and system for element values of vertical profile to geographic map

    CN112102425A

  • Projection calculation method from single-element change curve to geographic map

    CN112102430A