Method and Device for Processing Data Table

By defining business coordinates for data table cells and performing coordinate conversion, the problem of data table annotation information being lost after operation is solved, and the stability of labeling performance and user experience are improved.

CN114579658BActive Publication Date: 2025-07-29ALIBABA (CHINA) CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210200247.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-02
Publication Date
2025-07-29
Estimated Expiration
2042-03-02

AI Technical Summary

Technical Problem

The labeling information in existing data tables is easily lost or unreadable when the rows and columns are added or columns are added or expanded, resulting in unstable labeling performance.

Method used

By defining the business coordinates of the data table cells, storing the annotation information and the business coordinates, and performing coordinate conversion to generate a stable data table to ensure that the annotation information is not lost after the data table operation.

Benefits of technology

Improve the stability of data table labeling performance, avoid the loss of labeling information after data table operation, and improve user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114579658B_ABST
    Figure CN114579658B_ABST
Patent Text Reader

Abstract

The present application provides a method and device for processing a data table. The method includes: when a control operation acting on the interface where the data table is located is detected, obtaining the business coordinates of a target cell, where the target cell includes a cell containing annotation information to be rendered, and the business coordinates of the target cell are used to indicate the combination of dimension values and the offset of the target cell in the row dimension and / or column dimension. Subsequently, through coordinate transformation, the view coordinates corresponding to the business coordinates of the target cell are obtained, and then, based on the view coordinates of the target cell, a data table containing the annotation information of the target cell is rendered. The above processing process can avoid the problem that the annotation information of the originally annotated cells is lost after the user performs control operations such as folding or expanding some summary nodes of the data table, and improve the stability of the annotation performance of the data table.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer application technologies, and in particular, to a method and device for processing data tables. Background Art

[0002] With the advent of the big data era, the analysis and processing of massive data have become particularly important. Data visualization can organize complex raw data into intuitive and effective data charts, which helps decision-makers obtain important information for analysis and decision-making.

[0003] Currently, common data tables include pivot tables and cross tables. A pivot table is an interactive table that can quickly summarize a large amount of data. It aggregates data based on one or more keys and distributes the data into a rectangular area according to the grouping keys on rows and columns. A cross table is a special pivot table mainly used for calculating grouped frequencies.

[0004] The above-mentioned data tables can all label the background color, foreground color, font, border, etc. for cells, but these labels are usually static. With the increase, decrease, hiding of rows and columns in the data table, or the folding and unfolding of the summary nodes in the cross table, the display of the labels in the data table will become invalid, lost, or unreadable. Summary of the Invention

[0005] Embodiments of this application provide a method and device for processing a data table to improve the stability of the annotation performance of the data table.

[0006] The first aspect of the embodiments of this application provides a method for processing a data table, including:

[0007] When detecting a control operation on the interface where the data table is located, obtain the business coordinates of the target cell, where the target cell includes the cell containing annotation information to be rendered, and the business coordinates are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension;

[0008] Determine the view coordinates of the target cell according to the business coordinates of the target cell, where the view coordinates are used to indicate the pixel coordinates of the target cell in the data table;

[0009] Render a data table containing the annotation information of the target cell according to the view coordinates of the target cell.

[0010] In an optional embodiment of the first aspect of this application, the target cell is located within the data table, and the business coordinates of the target cell include at least one of the following:

[0011] The business coordinates of the target cell located in the row header area of the data table include the combination of dimension values of the row dimension and the column number;

[0012] The business coordinates of the target cell located in the column header area of the data table include the combination of dimension values of the column dimension and the row number;

[0013] The business coordinates of the target cell located in the data area of the data table include the combination of dimension values of the row dimension and the combination of dimension values of the column dimension.

[0014] In an alternative embodiment of the first aspect of the present application, the target cell is located outside the data table, and the business coordinates of the target cell include at least one of the following:

[0015] The business coordinates of the target cell located in the extended area of the row header area of the data table include the combination of dimension values of the row dimension at the bottom of the row header area, the column number, and the row number offset;

[0016] The business coordinates of the target cell located in the extended area of the column header area of the data table include the combination of dimension values of the column dimension on the rightmost side of the column header area, the row number, and the column number offset;

[0017] The business coordinates of the target cell located in the extended area of the data area of the data table include the combination of dimension values of the row dimension of the reference cell, the combination of dimension values of the column dimension of the reference cell, the row number offset, and the column number offset; the reference cell is the cell in the data area with the shortest view distance from the target cell.

[0018] In an alternative embodiment of the first aspect of the present application, determining the view coordinates of the target cell according to the business coordinates of the target cell includes:

[0019] Determine the business coordinate offset of the target cell relative to the reference cell according to the business coordinates of the target cell;

[0020] Determine the view coordinates of the target cell according to the view coordinates of the reference cell and the business coordinate offset of the target cell relative to the reference cell.

[0021] In an alternative embodiment of the first aspect of the present application, the method further includes:

[0022] Obtain the annotation information and / or data of the target cell from the database according to the business coordinates of the target cell; the database is used to store the business coordinates of the cells containing annotation information and / or data in the data table and the business coordinates of the blank cells.

[0023] In an alternative embodiment of the first aspect of the present application, the annotation information of the target cell includes at least one of the following information:

[0024] The background color, foreground color, icon, mark, font, border, graphic, and doodle of the target cell.

[0025] The second aspect of the embodiments of the present application provides a method for processing a data table, including:

[0026] When a marking operation acting on the interface where the data table is located is detected, obtain the view coordinates of the target cell, where the target cell is the cell containing the annotation information, and the view coordinates are used to indicate the pixel coordinates of the target cell in the data table;

[0027] Determine the service coordinates of the target cell according to the view coordinates of the target cell, where the service coordinates are used to indicate the dimension value combination and offset of the target cell in the row dimension and / or column dimension;

[0028] Store the annotation information and the service coordinates of the target cell.

[0029] In an alternative embodiment of the second aspect of the present application, the target cell is located within the data table, and the service coordinates of the target cell include at least one of the following:

[0030] The service coordinates of the target cell located in the row header area of the data table include the dimension value combination in the row dimension and the column number;

[0031] The service coordinates of the target cell located in the column header area of the data table include the dimension value combination in the column dimension and the row number;

[0032] The service coordinates of the target cell located in the data area of the data table include the dimension value combination in the row dimension and the dimension value combination in the column dimension.

[0033] In an alternative embodiment of the second aspect of the present application, the target cell is located outside the data table, and the service coordinates of the target cell include at least one of the following:

[0034] The service coordinates of the target cell located in the extended area of the row header area of the data table include the dimension value combination of the bottommost row dimension in the row header area, the column number, and the row number offset;

[0035] The service coordinates of the target cell located in the extended area of the column header area of the data table include the dimension value combination of the rightmost column dimension in the column header area, the row number, and the column number offset;

[0036] The service coordinates of the target cell located in the extended area of the data area of the data table include the combination of dimension values of the row dimension of the reference cell, the combination of dimension values of the column dimension of the reference cell, the row number offset, and the column number offset; the reference cell is the cell in the data area with the shortest view distance from the target cell.

[0037] In an alternative embodiment of the second aspect of the present application, the target cell includes a cell within the data table and / or a cell outside the data table; determining the service coordinates of the target cell according to the view coordinates of the target cell includes:

[0038] Determine the reference cell corresponding to the target cell;

[0039] According to the view coordinates of the target cell and the view coordinates of the reference cell, determine the service coordinate offset of the target cell relative to the reference cell;

[0040] According to the service coordinates of the reference cell and the service coordinate offset of the target cell relative to the reference cell, determine the service coordinates of the target cell.

[0041] In an alternative embodiment of the second aspect of the present application, if the target cell is a cell outside the data table, determining the reference cell corresponding to the target cell includes:

[0042] Use the cell in the data table with the shortest view distance from the target cell as the reference cell corresponding to the target cell.

[0043] In an alternative embodiment of the second aspect of the present application, if the target cell is a cell within the data table, determining the reference cell corresponding to the target cell includes:

[0044] Use the cell in the upper left corner of the cell matrix where the target cell is located as the reference cell corresponding to the target cell.

[0045] In an alternative embodiment of the second aspect of the present application, the annotation information of the target cell includes at least one of the following information:

[0046] The background color, foreground color, icon, mark, font, border, graphic, and graffiti of the target cell.

[0047] The third aspect of the embodiments of the present application provides a processing device for a data table, including:

[0048] When the detection module detects a control operation acting on the interface where the data table is located, an acquisition module is used to acquire the business coordinates of a target cell, where the target cell includes a cell containing annotation information to be rendered, and the business coordinates are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension;

[0049] A processing module is used to determine the view coordinates of the target cell according to the business coordinates of the target cell, and the view coordinates are used to indicate the pixel coordinates of the target cell in the data table;

[0050] A rendering module is used to render and generate a data table containing the annotation information of the target cell according to the view coordinates of the target cell.

[0051] A fourth aspect of the embodiments of the present application provides a processing device for a data table, including:

[0052] When the detection module detects an annotation operation acting on the interface where the data table is located, an acquisition module is used to acquire the view coordinates of a target cell, where the target cell is a cell containing annotation information, and the view coordinates are used to indicate the pixel coordinates of the target cell in the data table;

[0053] A processing module is used to determine the business coordinates of the target cell according to the view coordinates of the target cell, and the business coordinates are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension;

[0054] A storage module is used to store the annotation information of the target cell and the business coordinates.

[0055] A fifth aspect of the embodiments of the present application provides an electronic device, including: a memory, a processor, and a computer program; the computer program is stored in the memory and is configured to be executed by the processor to implement the method according to any one of the first aspect of the present application, or the method according to any one of the second aspect of the present application.

[0056] A sixth aspect of the embodiments of the present application provides a computer-readable storage medium, on which a computer program is stored, and the computer program is executed by a processor to implement the method according to any one of the first aspect of the present application, or the method according to any one of the second aspect of the present application.

[0057] A seventh aspect of the embodiments of the present application provides a computer program product, including a computer program, and when the computer program is executed by a processor, it implements the method according to any one of the first aspect of the present application, or the method according to any one of the second aspect of the present application.

[0058] An embodiment of the present application provides a method and device for processing a data table. The method includes: when a control operation acting on the interface where the data table is located is detected, obtaining the business coordinates of a target cell, where the target cell includes a cell containing annotation information to be rendered, and the business coordinates of the target cell are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension. Subsequently, through coordinate conversion, the view coordinates corresponding to the business coordinates of the target cell are obtained, and then, based on the view coordinates of the target cell, a data table containing the annotation information of the target cell is rendered. The above processing process can avoid the problem that the annotation information of the originally annotated cells is lost after the user performs control operations such as folding or expanding some summary nodes of the data table, and improve the stability of the annotation performance of the data table. Description of the Drawings

[0059] Figure 1 Schematic structural diagram of the data table provided by the embodiment of the present application Figure 1 ;

[0060] Figure 2 Schematic structural diagram of the data table provided by the embodiment of the present application Figure 2 ;

[0061] Figure 3 Schematic diagram of an example of the data table provided by the embodiment of the present application;

[0062] Figure 4 Schematic diagram of the change of the data table in the prior art;

[0063] Figure 5 Schematic structural diagram of the data table provided by the embodiment of the present application Figure 3 ;

[0064] Figure 6 Schematic flowchart of the method for processing the data table provided by the embodiment of the present application Figure 1 ;

[0065] Figure 7 Schematic diagram of coordinate conversion in the process of rendering the annotation information of the data table in the embodiment of the present application;

[0066] Figure 8 Schematic diagram of the annotation information of the cells in the data table provided by the embodiment of the present application;

[0067] Figure 9 Schematic diagram of the change of the annotation information of the cells outside the data table in the prior art;

[0068] Figure 10 Schematic diagram of the change of the annotation information of the cells outside the data table in the embodiment of the present application;

[0069] Figure 11Flow schematic of the method for processing the data table provided in the embodiment of the present application Figure 2 ;

[0070] Figure 12 Schematic diagram of coordinate conversion in the process of storing annotation information of the data table in the embodiment of the present application;

[0071] Figure 13 Schematic diagram of the position of the reference cell of the external cell of the data table provided in the embodiment of the present application;

[0072] Figure 14 Flow schematic diagram of the annotation and rendering of the data table provided in the embodiment of the present application;

[0073] Figure 15 Structural schematic of the data table processing device provided in the embodiment of the present application Figure 1 ;

[0074] Figure 16 Structural schematic of the data table processing device provided in the embodiment of the present application Figure 2 ;

[0075] Figure 17 Hardware structure diagram of the electronic device provided in the embodiment of the present application. Detailed implementation manners

[0076] To make the objectives, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present application. Obviously, the described embodiments are some, but not all, of the embodiments of the present application. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present application without creative efforts shall fall within the protection scope of the present application.

[0077] It should be understood that the terms "including" and "having" and any variations thereof used herein 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 clearly listed, but may include other steps or units not clearly listed or inherent to these process, method, product or device.

[0078] In the description of the embodiments of the present application, the term "corresponding" may indicate a direct or indirect corresponding relationship between two, may also indicate an associated relationship between two, or may be a relationship such as indication and being indicated, configuration and being configured, etc.

[0079] Existing data tables such as Excel pivot tables support annotating information such as background, font, and border for cells. However, the annotations in Excel are made on the view coordinates of the data table. In the current display state of the data table, the view coordinates are fixed. As the data table is updated, such as operations like adding or deleting rows and columns, collapsing or expanding summary nodes, or hiding rows and columns, the view coordinates of each cell in the data table will change, and the previous annotations will be distorted, such as the annotation information becoming invalid or partially lost.

[0080] To solve the above problems, an embodiment of the present application proposes a method for processing a data table. By defining the business coordinates of the cells in the data table, the business coordinates are used to indicate the combination of dimension values and offsets of the cell in the row dimension and / or column dimension. When a certain cell in the data table is annotated, the view coordinates of the annotated cell in the current data table are converted into the corresponding business coordinates, and the annotation information of the annotated cell and the business coordinates of the cell are stored in the database. After completing the cell annotation, when the data table is re-rendered by collapsing or expanding some summary nodes of the data table, the business coordinates and annotation information of the cells to be rendered are obtained, the business coordinates of the cells to be rendered are converted into the view coordinates of the cells to be rendered in the current data table, and a new data table is rendered according to the view coordinates and annotation information of the cells to be rendered.

[0081] The above solution has the following beneficial effects: Since the business coordinates of the cell indicate the business semantics of the cell and the business semantics of the cell are unchanged, the stability of the business coordinates of the cell is higher than that of the view coordinates of the cell. Caching or storing the annotation information of the annotated cell and the business coordinates of the annotated cell can avoid the problem of the loss of the annotation information of the annotated cell after the user collapses or expands some summary nodes of the data table, improve the annotation experience of the data table, and at the same time improve the stability of the data table annotation performance.

[0082] The method for processing a data table provided by an embodiment of the present application can be applied to a multi-dimensional data analysis scenario, especially a data cross-table scenario. Based on the row dimension and column dimension, a large number of dimensions and data are constructed, and the data table provides numerous analysis perspectives for users. Combining the storage and rendering process of the annotation information of the data table in this case, decision-makers can only focus on the information of the annotated cells in the data table. For the control operations of decision-makers, the annotation information of the annotated cells will not become invalid or lost, which can improve the user experience.

[0083] For ease of understanding, first, the data table involved in the embodiment of the present application will be briefly introduced in combination with several attached drawings.

[0084] Figure 1 The structural schematic of the data table provided by the embodiment of the present application Figure 1 。 Figure 1The data table shown can be abstracted into the following several regions: the upper left header, the column header region, the upper right header, the row header region, the data region, the row footer region, the lower left header, the column footer region, and the lower right header. Usually, the row header region is determined by the dimension of the data, such as province, city, etc.; the column header region is determined by the measurement of the data, such as the number of product orders, the order amount, etc.

[0085] Figure 2 Schematic structure of the data table provided by the embodiment of the present application Figure 2 。And Figure 1 Different from Figure 2 the data table shown only includes four regions, namely the upper right header, the column header region, the row header region, and the data region. Figure 2 The data table shown can be abstracted into three regions, denoted as Region 1, Region 2, and Region 3 respectively. Region 1 is the extended region of the row header region, Region 2 is the extended region of the data region, and Region 3 is the extended region of the column header region.

[0086] For traditional data tables, when displaying a large amount of data, the data is mainly displayed in a tiled manner, that is, the cells in the row header region are only a vertical column of cells, and the cells in the column header region are only a horizontal column of cells.

[0087] When the cell data in the row header region / column header region of the data table includes multiple sub-cell data, when viewing the row / column corresponding to the sub-cell data, on the basis of the original cell structure, expand the row / column corresponding to the sub-cell data. When there is no need to view the row / column corresponding to the sub-cell data, the row / column corresponding to the sub-cell data can be collapsed.

[0088] Exemplarily, Figure 3 Example diagram of the data table provided by the embodiment of the present application. Figure 3 The cell data “Province A” in the row header region of the data table in state 1 shown includes two sub-cell data, “City A1” and “City A2”. The cell data “Office Supplies” in the column header region includes three sub-cell data, “Notebook”, “Sticky Note”, and “Tape”. The cell data in the data region is used to indicate the order quantity of office supplies in different regions. Based on the data table in state 1, by clicking the folding control in the “Province A” cell, the cells in the rows where “City A1” and “City A2” are located can be collapsed to obtain the data table in state 2. Based on the data table in state 1, by clicking the folding control in the “Office Supplies” cell, the cells in the columns where “Notebook”, “Sticky Note”, and “Tape” are located can be collapsed to obtain the data table in state 3.

[0089] Exemplarily, Figure 4 Schematic diagram of the change of the data table in the prior art. The user is based on Figure 3The data table shown below has the background colors of some cells in the data table marked, such as Figure 4 The gray area in the data table above is the marked area. When the user clicks to collapse "Office Supplies" and then clicks to expand "Office Supplies" again. Since the existing markings are based on view coordinates, when the data table is expanded again, the original markings will be disordered, such as Figure 4 As shown in the data table below, after expanding "Office Supplies" again, the background colors of some cells are lost.

[0090] It should be noted that Figure 4 It shows that the user clicks the collapse / expand control on the interface where the data table is located by touching the screen with a finger. In some scenarios, the user can also click the collapse / expand control on the interface where the data table is located with a mouse. This embodiment does not make specific limitations on this.

[0091] To avoid the loss of marked information in the data table, this application defines the business coordinates of the cells in the data table. The business coordinates indicate the combination of dimension values and offsets of the cell in the row dimension and / or column dimension. The offset includes the offset in the row dimension and the offset in the column dimension. It should be understood that the offsets of the reference cells are all 0. The business coordinates of the cell indicate the business semantics of the cell, and the business semantics of the cell are usually fixed.

[0092] Next, in combination with the attached Figure 5 The business coordinates of the cells in the data table will be described in detail. Figure 5 It is a schematic structure of the data table provided by the embodiment of this application Figure 3 As Figure 5 shown, the data table includes four dimensions, denoted as A, B, C, and D respectively, where A and B are row dimensions, and C and D are column dimensions.

[0093] The row dimension can be expressed as: [dimension A - dimension value ai, dimension B - dimension value bj], such as [a1, b1]. a1 and b1 are the combination of dimension values in the row dimension.

[0094] The column dimension can be expressed as: [dimension C - dimension value ci, dimension D - dimension value dj], such as [c1, d1]. c1 and d1 are the combination of dimension values in the column dimension.

[0095] Among them, i and j are positive integers, and the dimension values of each dimension are positive integers.

[0096] Figure 5 The business coordinates of the cells in different areas of the data table shown are respectively expressed as:

[0097] (1) The business coordinates of the cells in the corner area: Fixed as [0, 0].

[0098] (2) Business coordinates of the cells in the row header area: [row dimension, column number]. Exemplarily, [a1, b1, 2] corresponds to Figure 5 the cell b1 in the row where a1 is located in the row header area shown.

[0099] (3) Business coordinates of the cells in the column header area: [column dimension, row number]. Exemplarily, [c1, d1, 2] corresponds to Figure 5 the cell d1 in the column where c1 is located in the column header area shown.

[0100] (4) Business coordinates of the cells in the data area: [row dimension, column dimension].

[0101] Figure 5 The business coordinates of the cells in different areas outside the data table shown are respectively represented as:

[0102] (1) Business coordinates of the cells in the extended area of the row header area: [the row dimension at the bottom of the row header area, column number, row offset]. Exemplarily, Figure 5 the area 1 shown is the extended area of the row header area of the data table. The reference cell of cell 1 in area 1 is the cell at the bottom of the row header area corresponding to cell 1, that is, the cell b3 in the row where a3 is located.

[0103] (2) Business coordinates of the cells in the extended area of the column header area: [the column dimension at the rightmost of the column header area, row number, column offset]. Exemplarily, Figure 5 the area 3 shown is the extended area of the column header area of the data table. The reference cell of cell 2 in area 3 is the cell at the rightmost of the column header area corresponding to cell 2, that is, the cell d3 in the column where c3 is located.

[0104] (3) Business coordinates of the cells in the extended area of the data area: [the row dimension of the reference cell, the column dimension of the reference cell, row offset, column offset], where the reference cell is the cell in the data area with the shortest view distance from the cell in the extended area of the data area. Exemplarily, Figure 5 the area 2 shown is the extended area of the data area of the data table. The reference cell corresponding to cell 3 in area 2 is cell 4, the reference cell corresponding to cell 5 is cell 6, and the reference cell corresponding to cell 7 is cell 8.

[0105] The technical solutions provided by the embodiments of the present application will be described in detail below through specific embodiments. It should be noted that the technical solutions provided by the embodiments of the present application may include some or all of the following contents. These specific embodiments below can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments.

[0106] Figure 6Flow schematic of the method for processing a data table provided in an embodiment of the present application Figure 1 The method for processing a data table in this embodiment involves the rendering process of annotation information in the data table. As Figure 6 shown, the method for processing this data table includes the following steps:

[0107] Step 101: When a control operation acting on the interface where the data table is located is detected, obtain the business coordinates of the target cell.

[0108] In an optional embodiment of this embodiment, when a control operation acting on the folding control on the interface where the data table is located is detected, obtain the business coordinates of the target cell. Exemplarily, as Figure 3 shown, when a control operation acting on the folding control in the "Province A" cell of the data table in State 1 is detected, collapse the cells in the rows where "City A1" and "City A2" are located, and obtain the business coordinates of the target cell to be rendered after the cells are collapsed.

[0109] In an optional embodiment of this embodiment, when a control operation acting on the expansion control on the interface where the data table is located is detected, obtain the business coordinates of the target cell. Exemplarily, as Figure 3 shown, when a control operation acting on the expansion control in the "Province A" cell of the data table in State 2 is detected, display the cells in the rows where "City A1" and "City A2" are located, and obtain the business coordinates of the target cell to be rendered after the cells are expanded.

[0110] It should be noted that while obtaining the business coordinates of the target cell, the annotation information corresponding to the business coordinates of the target cell can be obtained.

[0111] The target cell includes the cell to be rendered that contains annotation information. Among them, the cells containing annotation information are divided into two categories. One category is the blank cell containing annotation information, that is, the cell without data, and the other category is the cell containing both annotation information and data. Optionally, in some embodiments, the target cell also includes the cell containing only data.

[0112] The business coordinates of the target cell are used to indicate the dimension values and offsets of the target cell in the row dimension and / or column dimension. Exemplarily, as Figure 5 shown, the business coordinates of the cells in the row header area of the data table are represented as [ai, bj, column number], the business coordinates of the cells in the column header area of the data table are represented as [ci, dj, row number], and the business coordinates of the cells in the data area of the data table are represented as [ai, bj, ci, dj]. Among them, ai and bj are the two dimension values in the row dimension. Similarly, ci and dj are the two dimension values in the column dimension.

[0113] Step 102: Determine the view coordinates of the target cell based on the business coordinates of the target cell. The view coordinates are used to indicate the pixel coordinates of the target cell in the data table.

[0114] In an alternative embodiment of this embodiment, first, determine the business coordinate offset of the target cell relative to the reference cell according to the business coordinates of the target cell; then, determine the view coordinates of the target cell according to the view coordinates of the reference cell and the business coordinate offset of the target cell relative to the reference cell. Among them, the business coordinate offset of the target cell relative to the reference cell includes: row dimension offset and / or column dimension offset.

[0115] As an example, if the target cell is a cell in the data table, usually the cell in the upper left corner of the cell matrix where the target cell is located is used as the reference cell of the target cell. Each cell in the cell matrix can be used to store data, and the cell matrix can be regarded as a data matrix. The business coordinate offset of the target cell relative to the reference cell can correspond to: the array subscript of the target cell data in the data matrix.

[0116] Exemplarily, a two-dimensional array corresponds to a cell matrix, and the target cell data a 11 has an array subscript of i = 1, j = 1 in the two-dimensional array. The business coordinate offset of the target cell relative to the reference cell includes a row dimension offset and a column dimension offset, and both the row dimension offset and the column dimension offset are 1.

[0117] Based on the above example, the business coordinate offset of the target cell relative to the reference cell can be regarded as the data coordinate of the target cell data in its data matrix, that is, the data coordinate of the target cell.

[0118] Figure 7 It is a schematic diagram of coordinate conversion in the process of rendering the annotation information of the data table in the embodiment of the present application. As Figure 7 shown, obtain the business coordinates of the target cell to be rendered, determine the data coordinates of the target cell based on the business coordinates of the target cell, and then determine the view coordinates of the target cell based on the data coordinates of the target cell and the view coordinates of the reference cell of the target cell.

[0119] Among them, the view coordinates of the cell include the table row number / canvas row coordinate, and the table column number / canvas column coordinate. The data coordinates of the cell include the array row subscript of the cell data in its data matrix, and the array column subscript of the cell data in its data matrix. The business coordinates of the cell include the row dimension and the column dimension.

[0120] As an example, if the target cell is a cell outside the data table, the cell in the data table with the shortest view distance from the target cell is usually used as the reference cell of the target cell. For a specific example, refer to the embodiments below.

[0121] Step 103: Render a data table containing the annotation information of the target cell according to the view coordinates of the target cell.

[0122] In an optional embodiment of this embodiment, according to the business coordinates of the target cell, obtain the annotation information of the target cell from the database, and then according to the view coordinates of the target cell and the annotation information of the target cell, render a data table containing the annotation information of the target cell.

[0123] In an optional embodiment of this embodiment, according to the business coordinates of the target cell, obtain the target cell data from the database, and then according to the view coordinates of the target cell and the target cell data, render a data table containing the target cell data.

[0124] In an optional embodiment of this embodiment, according to the business coordinates of the target cell, obtain the annotation information and data of the target cell from the database, and then according to the view coordinates of the target cell and the annotation information and data of the target cell, render a data table containing the annotation information and data of the target cell. Among them, the database is used to store the business coordinates of the cells containing annotation information and / or data in the data table and the business coordinates of blank cells. Optionally, the database is a cache database.

[0125] Optionally, the annotation information of the target cell includes at least one of the following information: the background color, foreground color, icon, mark, font, border, graphic, and graffiti of the target cell.

[0126] Figure 8 It is a schematic diagram of the annotation information of the cells in the data table provided by the embodiment of the present application. Figure 8 The shown annotations are as follows: the background color of the cell marking the column of the summary of office supplies, bolding the data in the cell of "Province A - Summary of Office Supplies", setting a border for the cell of "City A2 - Post-it Notes", setting icons ① and ② for the two cells of "City A1" and "City A2" respectively, and setting arrow graphics for the cells of "Province A - Notebooks", "Province A - Post-it Notes", and "Province A - Tape" respectively. The arrow graphics are used to indicate the change situation of the data in the cells, such as indicating that the data value in the cell increases, decreases, or remains unchanged.

[0127] It should be noted that Figure 7The annotation information shown is only an example. Other annotation information that serves as identification, marking, or reminder, such as modifying the font color of a cell, all belongs to the protection scope of the embodiments of this application.

[0128] The method for processing a data table provided by the embodiments of this application, when detecting a control operation acting on the interface where the data table is located, obtains the business coordinates of the target cell, where the target cell includes the cell containing annotation information to be rendered, and the business coordinates of the target cell are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension. Subsequently, through coordinate conversion, the view coordinates corresponding to the business coordinates of the target cell are obtained, and then, based on the view coordinates of the target cell, a data table containing the annotation information of the target cell is rendered. The above processing process can avoid the problem that the annotation information of the originally annotated cells is lost after the user performs control operations such as folding or expanding certain summary nodes of the data table, improve the stability of the data table annotation performance, and enhance the user experience.

[0129] Based on the above embodiments, if the originally annotated cell is a cell within the data table, for example Figure 4 as shown in the above data table, the annotation of the cell background color. After the user clicks to collapse "Office Supplies" and then clicks to expand "Office Supplies" again, by executing the above method for processing the data table, the data table is re-rendered. Different from the prior art, the annotation information of the cell is recorded based on the business coordinates of the cell. Therefore, the background color of the originally annotated cells in the data table will not be lost due to multiple control operations by the user.

[0130] Based on the above embodiments, if the originally annotated cell is a cell outside the data table, the relative position of the annotated cell and the data table will not change due to control operations such as folding or expanding the summary nodes within the data table by the user.

[0131] For ease of understanding, the following combines Figure 9 and Figure 10 to illustrate by way of example the change situation of the annotation information of cells outside the data table. Exemplarily, Figure 9 is a schematic diagram of the change of the annotation information of cells outside the data table in the prior art, Figure 10 is a schematic diagram of the change of the annotation information of cells outside the data table in the embodiments of this application.

[0132] Such as Figure 9As shown in the figure, the remarks information of the data table is recorded in the cell with the background color of the area outside the data table marked as gray. The view coordinates of this cell can be expressed as (9, A), and the row offset of this cell from its reference cell (i.e., the cell with view coordinates (6, A)) is 2. When the user clicks to collapse "Province A", the above-mentioned marked cell in the area outside the data table is re-rendered using the existing technology. The view coordinates of this cell remain unchanged, and the row offset of this cell from its reference cell in the new data table (i.e., the cell with view coordinates (4, A)) is 4. It can be understood that when the number of folded rows in the data table is large, for example, when 10 rows of data are collapsed, the relative position change of the marked cell outside the data table with respect to the data table is huge, that is Figure 9 the row offset in Figure 9 increases, which is not conducive to viewing the information outside the table.

[0133] As Figure 10 shown, based on the same data table and the user's control operation, the above-mentioned marked cell in the area outside the data table is re-rendered using the processing method of the above embodiment. The marked information of this cell is recorded by business coordinates. During the rendering process, coordinate conversion is performed based on the business coordinates of the cell to obtain the view coordinates (7, A) of this cell in the new data table, so as to determine that the row offset of this cell from its reference cell in the new data table (i.e., the cell with view coordinates (4, A)) remains unchanged, still being 4.

[0134] By comparison, it can be seen that using the processing method of the data table provided in this embodiment can ensure that the relative position of the marked cell in the area outside the data table with respect to the data table remains unchanged, which is conducive to viewing the information outside the table, and is particularly suitable for data tables with a large amount of data (i.e., data tables with a large number of rows and columns).

[0135] The above embodiment shows the rendering process of the marked cell in the data table. The first step of the rendering process includes obtaining the business coordinates of the marked cell, which are data pre-stored locally in the processing device or equipment. The following uses a specific embodiment to detail the storage process of the marked information of the marked cell in the data table.

[0136] Figure 11 is a schematic flow chart of the processing method of the data table provided by the embodiment of the present application Figure 2 。The processing method of the data table in this embodiment involves the storage process of the marked information in the data table. As Figure 11 shown, the processing method of this data table includes the following steps:

[0137] Step 201: When a marking operation acting on the interface where the data table is located is detected, obtain the view coordinates of the target cell.

[0138] In this embodiment, the target cell is a cell containing annotation information. The view coordinates of the target cell are used to indicate the pixel coordinates of the target cell in the current data table.

[0139] Optionally, the target cell can be a cell manually annotated by the user, and / or a cell annotated by anomaly detection or attribution analysis.

[0140] Among them, anomaly detection can be used to detect the format of cell data, data statistical results, etc. in the data table. The anomaly cells in the data table can be obtained through the anomaly detection module in the processing device or equipment, and the anomaly cells can be automatically annotated or marked.

[0141] Among them, attribution analysis can be used to detect the cells with correlation relationships in the data table. Multiple cells with correlation relationships in the data table can be obtained through the attribution analysis module in the processing device or equipment, and these multiple cells can be automatically annotated or marked. Exemplarily, if the data in cell 1 is determined according to the data in cells 3 and 4, there is a correlation relationship among cells 1, 3, and 4.

[0142] Optionally, the target cell includes cells within the data table and / or cells outside the data table.

[0143] Optionally, the annotation information of the target cell includes at least one of the following information: the background color, foreground color, icon, mark, font, border, graphic, and graffiti of the target cell.

[0144] Based on the user's annotation operation, the corresponding annotation information is generated. Exemplarily, when the user annotates the background color of a cell as yellow, the background color is included in the annotation information of the cell; when the user records a text note in a cell outside the data table, the text note is included in the annotation information of the cell; when the user adds an icon to a cell, the icon is included in the annotation information of the cell.

[0145] Based on the user's annotation operation, while generating the corresponding annotation information, the view coordinates of the target cell in the interface where the current data table is located are obtained.

[0146] Step 202: Determine the business coordinates of the target cell according to the view coordinates of the target cell.

[0147] The business coordinates of the target cell are used to indicate the dimension values and offsets of the target cell in the row dimension and / or column dimension. For specific examples, reference can be made to the above embodiments, and details are not described here again.

[0148] In an alternative embodiment of this embodiment, the service coordinates of the target cell can be determined through the following steps: Determine the reference cell corresponding to the target cell; Determine the service coordinate offset of the target cell relative to the reference cell according to the view coordinates of the target cell and the view coordinates of the reference cell; Determine the service coordinates of the target cell according to the service coordinates of the reference cell and the service coordinate offset of the target cell relative to the reference cell. Among them, the service coordinate offset of the target cell relative to the reference cell includes: row dimension offset and / or column dimension offset.

[0149] As an example, if the target cell is a cell in a data table, determining the reference cell corresponding to the target cell includes: Using the cell in the upper left corner of the cell matrix where the target cell is located as the reference cell corresponding to the target cell.

[0150] Each cell in the cell matrix can be used to store data. The cell matrix can be regarded as a data matrix. The service coordinate offset of the target cell relative to the reference cell can correspond to: the array subscript of the target cell data in the data matrix. Therefore, the service coordinate offset of the target cell relative to the reference cell can be regarded as the data coordinate of the target cell data in its data matrix, that is, the data coordinate of the target cell.

[0151] Figure 12 It is a schematic diagram of coordinate conversion for the storage process of data table annotation information in the embodiments of this application. As Figure 12 shown, obtain the view coordinates of the target cell to be annotated in the interface where the current data table is located. Based on the view coordinates of the target cell and the view coordinates of its reference cell, determine the data coordinates of the target cell, and then based on the data coordinates of the target cell and the service coordinates of its reference cell, determine the service coordinates of the target cell. It should be noted that without adding or deleting rows and columns, the service coordinates of the cells inside and outside the data table are fixed and unchanged.

[0152] As an example, if the target cell is a cell outside the data table, determining the reference cell corresponding to the target cell includes: Using the cell in the data table with the shortest view distance from the target cell as the reference cell corresponding to the target cell.

[0153] Figure 13 It is a schematic diagram of the position of the reference cell of the cell outside the data table provided by the embodiments of this application. Outside the data table, it can be divided as Figure 13The three regions shown are respectively denoted as region A, region B, and region C. Among them, the reference cell corresponding to cell 1 in region A is cell 2, and the view distance between cell 1 and cell 2 in the data table is the shortest. The reference cell corresponding to cell 3 in region B is cell 4, and the view distance between cell 3 and cell 4 in the data table is the shortest. The reference cell corresponding to cell 5 in region C is cell 6, and the view distance between cell 5 and cell 6 in the data table is the shortest.

[0154] Step 203: Store the annotation information and business coordinates of the target cell.

[0155] After obtaining the annotation information and business coordinates of the target cell, the annotation information and business coordinates of the target cell are correspondingly stored in a processing device or equipment, for example, stored in the cache of the processing device or equipment.

[0156] In this embodiment, the folding or unfolding of a certain row or column in the data table may cause a change in the view coordinates of the target cell, but the business coordinates of the target cell are usually unchanged, that is, the stability of the business coordinates of the cell is higher than that of the view coordinates of the cell. By correspondingly storing the business coordinates of the target cell and the annotation information of the target cell, the invalidation or loss of the annotation information of the cell during the re-rendering of the data table can be avoided.

[0157] The data table processing method provided by the embodiment of the present application, when detecting an annotation operation on the interface where the data table is located, first obtains the view coordinates of the target cell in the current data table, where the target cell is the cell containing the annotation information. Subsequently, through coordinate conversion, the business coordinates corresponding to the view coordinates of the target cell are obtained, where the business coordinates of the target cell are used to indicate the dimension value combination and offset of the target cell in the row dimension and / or column dimension. Finally, the annotation information and business coordinates of the target cell are correspondingly stored. The above processing process stores the annotation information of the annotated cell corresponding to the business coordinates of the cell, which can avoid the invalidation or loss of the annotation information of the annotated cell when the annotated cell in the data table is re-rendered.

[0158] Figure 14 It is a schematic flowchart of the annotation and rendering of the data table provided by the embodiment of the present application. As Figure 14 shown, the user enters the data cross-table, initializes the cross-table. Based on the configuration information of the cross-table, the business coordinates of the cell can be generated according to the view coordinates and data coordinates of the cross-table cell, so as to achieve the complete alignment of the three coordinate matrices.

[0159] In one application scenario, when a user enters the cross-tab editing state (that is, opens the designer), the cross-tab enters design mode, allowing the user to self-annotate the background color, font, layout, border, and other aspects of the cell in the data table interface. Based on the user's self-annotation, the view coordinates and data coordinates of the annotated cell are obtained, and then the business coordinates of the annotated cell are determined. Finally, the design style / format is cached based on the cell's business coordinates, that is, the design information (i.e., annotation information) is saved for subsequent data table refreshes / queries.

[0160] In another application scenario, when the designer is not open, perform anomaly detection or attribution analysis on a data table. Based on the anomaly detection or attribution analysis results, you can automatically annotate related cells in a crosstab. For example, you can annotate cells with abnormal data in a crosstab or annotate multiple cells with related relationships in a crosstab. Cell annotation information is also saved based on the cell's business coordinates.

[0161] In another application scenario, based on the cell annotation information stored in any of the above scenarios, when the user collapses or expands a summary node of the cross-tab, the business coordinates and data coordinates of the annotated cell to be rendered are obtained to determine the view coordinates of the cell, and finally the cell annotation information (or rendering design style / format) is rendered based on the cell view coordinates.

[0162] Based on the above embodiments, the innovative features of the data table processing method provided in the embodiments of the present application are summarized as follows:

[0163] First, in the multi-dimensional view of the crosstab / pivot table, we draw on the annotation of business coordinates in financial market charts and innovate the annotation scheme. By self-service or automatic annotation of crosstab row dimensions, column dimensions, corner headers, data, and other area cells, including annotation of background, foreground, font, layout, border, copy, etc., decision makers generally have scarce time and attention. This allows them to focus on less, more critical, and more personalized information, thereby improving the efficiency of analytical decision-making. At the same time, it can provide subsequent algorithm models (such as attribution, volatility analysis, etc.) with self-service annotation features based on human expert experience.

[0164] Second, in cross-tab / pivot table scenarios, innovatively define the business coordinates of each view coordinate / view cell. For each view coordinate (inside or outside the cross-tab) / view cell, generate more stable business coordinates based on its view coordinates, data coordinates, and business semantics, such as the row header area, column header area, corner header area, data area, and business coordinates of empty cells. Clarify the business semantics of each view cell, so that the view coordinates, data coordinates, and business coordinates are connected in the cross-tab scenario, and the three coordinate matrices are fully aligned. Coordinate definition is not limited to application in cross-tab scenarios.

[0165] Third, in the scenario of crosstab / pivot table, from the perspective of the stability and consistency of the three coordinates, the business coordinate > data coordinate > view coordinate. Because the data coordinate will change due to changes in business rules (such as inserting blank rows and columns, adding calculated rows and columns, hiding rows and columns, etc.), and the view coordinate will change due to crosstab interactions (such as collapsing / expanding summary nodes). However, regardless of how the data coordinate and view coordinate change, the business semantics of the crosstab rows and columns remain unchanged. Based on this understanding, the annotation and rendering processes of innovative cells are as follows: when annotating cells: view coordinate → data coordinate → business coordinate → cache or storage; when rendering cells: business coordinate → data coordinate → view coordinate → rendering. The above two processes can improve the stability of the data table annotation performance and rendering performance.

[0166] The above describes the processing method of the data table provided by the embodiments of the present application. Next, the processing device of the data table provided by the embodiments of the present application will be described.

[0167] The embodiments of the present application can divide the functional modules of the processing device of the data table according to the above method embodiments. For example, each functional module can be corresponding to each function, or two or more functions can be integrated into one processing module. The above integrated module can be implemented in the form of hardware or in the form of a software functional module.

[0168] It should be noted that the division of modules in the embodiments of the present application is illustrative, merely a logical function division, and there may be other division methods in actual implementation. Next, an example of dividing each functional module corresponding to each function will be used for description.

[0169] Figure 15 is the structural schematic of the processing device of the data table provided by the embodiments of the present application Figure 1 As Figure 15 shown, the processing device 300 of the data table provided by this embodiment includes: a detection module 301, an acquisition module, a processing module 302, and a rendering module 303.

[0170] When the detection module 301 detects a control operation acting on the interface where the data table is located, the acquisition module is used to acquire the business coordinates of the target cell, where the target cell includes the cell containing annotation information to be rendered, and the business coordinates are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension;

[0171] The processing module 302 is used to determine the view coordinates of the target cell according to the business coordinates of the target cell, and the view coordinates are used to indicate the pixel coordinates of the target cell in the data table;

[0172] The rendering module 303 is configured to render and generate a data table containing the annotation information of the target cell according to the view coordinates of the target cell.

[0173] In an alternative embodiment of this embodiment, the target cell is located within the data table, and the service coordinates of the target cell include at least one of the following:

[0174] The service coordinates of the target cell located in the row header area of the data table include the combination of dimension values of the row dimension and the column number;

[0175] The service coordinates of the target cell located in the column header area of the data table include the combination of dimension values of the column dimension and the row number;

[0176] The service coordinates of the target cell located in the data area of the data table include the combination of dimension values of the row dimension and the combination of dimension values of the column dimension.

[0177] In an alternative embodiment of this embodiment, the target cell is located outside the data table, and the service coordinates of the target cell include at least one of the following:

[0178] The service coordinates of the target cell located in the extended area of the row header area of the data table include the combination of dimension values of the row dimension at the bottom of the row header area, the column number, and the row number offset;

[0179] The service coordinates of the target cell located in the extended area of the column header area of the data table include the combination of dimension values of the column dimension on the rightmost side of the column header area, the row number, and the column number offset;

[0180] The service coordinates of the target cell located in the extended area of the data area of the data table include the combination of dimension values of the row dimension of the reference cell, the combination of dimension values of the column dimension of the reference cell, the row number offset, and the column number offset; the reference cell is the cell in the data area with the shortest view distance from the target cell.

[0181] In an alternative embodiment of this embodiment, the processing module 302 is configured to:

[0182] Determine the service coordinate offset of the target cell relative to the reference cell according to the service coordinates of the target cell;

[0183] Determine the view coordinates of the target cell according to the view coordinates of the reference cell and the service coordinate offset of the target cell relative to the reference cell.

[0184] In an alternative embodiment of this embodiment, the acquisition module is configured to:

[0185] Obtain the annotation information and / or data of the target cell from the database according to the business coordinates of the target cell; the database is used to store the business coordinates of the cells containing annotation information and / or data and the business coordinates of blank cells in the data table.

[0186] In an optional embodiment of this embodiment, the annotation information of the target cell includes at least one of the following information: the background color, foreground color, icon, mark, font, border, graphic, and graffiti of the target cell.

[0187] The data table processing device provided in this embodiment can execute the technical solutions of the method embodiment shown above. Figure 6 The implementation principle and technical effects are similar and will not be elaborated here.

[0188] Figure 16 This is the second structural schematic diagram of the data table processing device provided in the embodiment of the present application. As Figure 16 shown, the data table processing device 400 provided in this embodiment includes: a detection module 401, an acquisition module 402, a processing module 403, and a storage module 404.

[0189] When the detection module 401 detects an annotation operation on the interface where the data table is located, the acquisition module 402 is used to acquire the view coordinates of the target cell, where the target cell is a cell containing annotation information, and the view coordinates are used to indicate the pixel coordinates of the target cell in the data table;

[0190] The processing module 403 is used to determine the business coordinates of the target cell according to the view coordinates of the target cell, where the business coordinates are used to indicate the dimension value combination and offset of the target cell in the row dimension and / or column dimension;

[0191] The storage module 404 is used to store the annotation information and the business coordinates of the target cell.

[0192] In an optional embodiment of this embodiment, the target cell is located within the data table, and the business coordinates of the target cell include at least one of the following:

[0193] The business coordinates of the target cell located in the row header area of the data table include the dimension value combination in the row dimension and the column number;

[0194] The business coordinates of the target cell located in the column header area of the data table include the dimension value combination in the column dimension and the row number;

[0195] The business coordinates of the target cell located in the data area of the data table include the combination of dimension values of the row dimension and the combination of dimension values of the column dimension.

[0196] In an alternative embodiment of this embodiment, the target cell is located outside the data table, and the business coordinates of the target cell include at least one of the following:

[0197] The business coordinates of the target cell located in the extended area of the row header area of the data table include the combination of dimension values of the row dimension at the bottommost of the row header area, the column number, and the row number offset;

[0198] The business coordinates of the target cell located in the extended area of the column header area of the data table include the combination of dimension values of the column dimension at the rightmost of the column header area, the row number, and the column number offset;

[0199] The business coordinates of the target cell located in the extended area of the data area of the data table include the combination of dimension values of the row dimension of the reference cell, the combination of dimension values of the column dimension of the reference cell, the row number offset, and the column number offset; the reference cell is the cell in the data area with the shortest view distance from the target cell.

[0200] In an alternative embodiment of this embodiment, the target cell includes the cell inside the data table and / or the cell outside the data table; the processing module 403 is configured to:

[0201] Determine the reference cell corresponding to the target cell;

[0202] Determine the business coordinate offset of the target cell relative to the reference cell according to the view coordinates of the target cell and the view coordinates of the reference cell;

[0203] Determine the business coordinates of the target cell according to the business coordinates of the reference cell and the business coordinate offset of the target cell relative to the reference cell.

[0204] In an alternative embodiment of this embodiment, if the target cell is a cell outside the data table, the processing module 403 is configured to:

[0205] Use the cell in the data table with the shortest view distance from the target cell as the reference cell corresponding to the target cell.

[0206] In an alternative embodiment of this embodiment, if the target cell is a cell inside the data table, the processing module 403 is configured to:

[0207] Use the cell in the upper left corner of the cell matrix where the target cell is located as the reference cell corresponding to the target cell.

[0208] In an alternative embodiment of this embodiment, the annotation information of the target cell includes at least one of the following information: the background color, foreground color, icon, mark, font, border, graphic, and graffiti of the target cell.

[0209] The data table processing device provided in this embodiment can execute the technical solutions of the method embodiment described above. Figure 11 The implementation principle and technical effects are similar, and will not be elaborated here.

[0210] Figure 17 This is the hardware structure diagram of the electronic device provided in the embodiment of the present application. As Figure 17 shown, the electronic device 500 provided in this embodiment includes:

[0211] A memory 501;

[0212] A processor 502; and

[0213] A computer program;

[0214] Among them, the computer program is stored in the memory 501 and is configured to be executed by the processor 502 to implement the technical solutions of any of the above method embodiments. The implementation principle and technical effects are similar, and will not be elaborated here.

[0215] Optionally, the memory 501 can be either independent or integrated with the processor 502. When the memory 501 is a device independent of the processor 502, the electronic device 500 further includes: a bus 503 for connecting the memory 501 and the processor 502.

[0216] The embodiment of the present application also provides a computer-readable storage medium, on which a computer program is stored, and the computer program is executed by the processor 502 to implement the technical solutions of any of the foregoing method embodiments.

[0217] The embodiment of the present application provides a computer program product, including a computer program, and the computer program implements the technical solutions of any of the foregoing method embodiments when executed by a processor.

[0218] The embodiment of the present application also provides a chip, including: a processing module and a communication interface, and the processing module can execute the technical solutions of any of the foregoing method embodiments.

[0219] Further, the chip further includes a storage module (e.g., a memory), the storage module is used to store instructions, the processing module is used to execute the instructions stored in the storage module, and the execution of the instructions stored in the storage module causes the processing module to execute the technical solutions of any of the foregoing method embodiments.

[0220] It should be understood that the foregoing processor may be a central processing unit (English: Central Processing Unit, abbreviated: CPU), or may also be other general-purpose processors, digital signal processors (English: Digital Signal Processor, abbreviated: DSP), application specific integrated circuits (English: Application Specific Integrated Circuit, abbreviated: ASIC), etc. The general-purpose processor may be a microprocessor or the processor may also be any conventional processor, etc. The steps of the method disclosed in combination with the invention can be directly embodied as being executed and completed by a hardware processor, or can be executed and completed by a combination of hardware and software modules in the processor.

[0221] The memory may include high-speed RAM memory, and may also include non-volatile storage NVM, such as at least one disk memory, and may also be a USB flash drive, a mobile hard disk, a read-only memory, a magnetic disk, or an optical disc, etc.

[0222] The bus may be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus, etc. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of representation, the bus in the drawings of the present application is not limited to only one bus or one type of bus.

[0223] The foregoing storage medium may be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disc. The storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.

[0224] An exemplary storage medium is coupled to a processor, enabling the processor to read information from the storage medium and write information to the storage medium. Of course, the storage medium can also be a component of the processor. The processor and the storage medium can be located in an Application Specific Integrated Circuits (ASIC). Of course, the processor and the storage medium can also exist as discrete components in an electronic device.

[0225] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements on some or all of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of the present application.

Claims

1. A method for processing a data table, characterized in that, including: When a control operation acting on the interface where the data table is located is detected, obtain the business coordinates of the target cell, where the target cell includes a cell containing annotation information to be rendered, and the business coordinates are used to indicate the combination of dimension values and offsets of the target cell in the row dimension and / or column dimension. The control operation includes a folding operation or an unfolding operation; Determine the view coordinates of the target cell according to the business coordinates of the target cell, where the view coordinates are used to indicate the pixel coordinates of the target cell in the data table; Render a data table containing the annotation information of the target cell according to the view coordinates of the target cell; The determining the view coordinates of the target cell according to the business coordinates of the target cell includes: Determine the business coordinate offset of the target cell relative to the reference cell according to the business coordinates of the target cell; Determine the view coordinates of the target cell according to the view coordinates of the reference cell and the business coordinate offset of the target cell relative to the reference cell.

2. The method according to claim 1, characterized in that The method further includes: Obtain the annotation information and / or data of the target cell from the database according to the business coordinates of the target cell; the database is used to store the business coordinates of the cells containing annotation information and / or data in the data table and the business coordinates of blank cells.

3. The method according to claim 1, wherein The target cell is located within the data table, and the business coordinates of the target cell include at least one of the following: The business coordinates of the target cell located in the row header area of the data table include the combination of dimension values in the row dimension and the column number; The business coordinates of the target cell located in the column header area of the data table include the combination of dimension values in the column dimension and the row number; The business coordinates of the target cell located in the data area of the data table include the combination of dimension values in the row dimension and the combination of dimension values in the column dimension.

4. The method according to claim 1, characterized in that, The target cell is located outside the data table, and the business coordinates of the target cell include at least one of the following: The business coordinates of the target cell located in the extended area of the row header area of the data table include the combination of dimension values in the row dimension at the bottom of the row header area, the column number, and the row offset; The business coordinates of the target cell located in the extended area of the column header area of the data table include the combination of dimension values in the column dimension at the rightmost of the column header area, the row number, and the column offset; The business coordinates of the target cell located in the extended area of the data area of the data table include the combination of dimension values in the row dimension of the reference cell, the combination of dimension values in the column dimension of the reference cell, the row offset, and the column offset; The reference cell is the cell in the data area with the shortest view distance from the target cell.

5. A method for processing a data table, characterized in that, including: When an annotation operation acting on the interface where the data table is located is detected, obtain the view coordinates of the target cell, where the target cell is a cell containing annotation information, and the view coordinates are used to indicate the pixel coordinates of the target cell in the data table; Determine the service coordinates of the target cell according to the view coordinates of the target cell, where the service coordinates are used to indicate the combination of dimension values and the offset in the row dimension and / or column dimension of the target cell; Store the annotation information and the service coordinates of the target cell; The target cell includes a cell within the data table and / or a cell outside the data table; The determining the service coordinates of the target cell according to the view coordinates of the target cell includes: Determine the reference cell corresponding to the target cell; Determine the service coordinate offset of the target cell relative to the reference cell according to the view coordinates of the target cell and the view coordinates of the reference cell; Determine the service coordinates of the target cell according to the service coordinates of the reference cell and the service coordinate offset of the target cell relative to the reference cell.

6. The method according to claim 5, wherein If the target cell is a cell outside the data table, the determining the reference cell corresponding to the target cell includes: Take the cell in the data table with the shortest view distance from the target cell as the reference cell corresponding to the target cell.

7. The method according to claim 5, wherein If the target cell is a cell within the data table, the determining the reference cell corresponding to the target cell includes: Take the cell in the upper left corner of the cell matrix where the target cell is located as the reference cell corresponding to the target cell.

8. The method according to claim 5, characterized in that, When the target cell is within the data table, the service coordinates of the target cell include at least one of the following: The service coordinates of the target cell located in the row header area of the data table include the combination of dimension values in the row dimension and the column number; The service coordinates of the target cell located in the column header area of the data table include the combination of dimension values in the column dimension and the row number; The service coordinates of the target cell located in the data area of the data table include the combination of dimension values in the row dimension and the combination of dimension values in the column dimension.

9. The method according to claim 5, wherein When the target cell is outside the data table, the service coordinates of the target cell include at least one of the following: The service coordinates of the target cell located in the extended area of the row header area of the data table include the combination of dimension values of the bottommost row dimension in the row header area, the column number, and the row number offset; The service coordinates of the target cell located in the extended area of the column header area of the data table include the combination of dimension values of the rightmost column dimension in the column header area, the row number, and the column number offset; The service coordinates of the target cell located in the extended area of the data area of the data table include the combination of dimension values of the row dimension of the reference cell, the combination of dimension values of the column dimension of the reference cell, the row number offset, and the column number offset; The reference cell is the cell in the data area with the shortest view distance from the target cell.

10. An electronic device, characterized in that, Includes: A memory, a processor, and a computer program; the computer program is stored in the memory and is configured to be executed by the processor to implement the method according to any one of claims 1-9.

Citation Information

Patent Citations

  • Chart generation method and device

    CN109871524A