Data table processing method and device, electronic equipment and storage medium
By identifying the time dimension fields and target metric fields in the data table, and processing the metric data according to the time interval, visual analysis results are generated, the problem of high threshold for traditional data analysis methods is solved, and efficient and accurate data analysis is achieved.
Patent Information
- Application Number
- CN202411967900.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-04-25
AI Technical Summary
Traditional data analysis methods have a high threshold for ordinary users and are difficult to meet users' urgent needs for efficient and accurate data analysis.
Provide a data table processing method. By obtaining the data table to be processed, identifying the time dimension field and the target metric field to be analyzed, and processing the measurement data items in the target metric field according to the time data items in the time dimension field according to the time data items in the time dimension field, and generating visual analysis results.
It lowers the threshold and complexity of data analysis, improves the efficiency and accuracy of data analysis, and provides users with a more convenient and intuitive data analysis method.
Smart Images

Figure CN119886083A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computers, and in particular to a data table processing method, device, electronic device and storage medium. Background Art
[0002] In today's era of rapid development of informatization, data processing and analysis have become an indispensable part of all industries.
[0003] Traditional data analysis methods often rely on users to have a strong statistical background and be proficient in complex date processing functions, data aggregation formulas, and the use of visualization tools. This undoubtedly sets a high threshold for ordinary users and makes it difficult to meet users' urgent needs for efficient and accurate data analysis. Summary of the invention
[0004] The present application provides a data table processing method, device, electronic device and storage medium to solve the technical problem that traditional data analysis methods have a high threshold for use by ordinary users and are difficult to meet users' urgent needs for efficient and accurate data analysis.
[0005] In a first aspect, the present application provides a method for processing a data table, the method comprising:
[0006] Get the data table to be processed;
[0007] Identifying a time dimension field and a target metric field to be analyzed in the data table;
[0008] According to the time data items in the time dimension field, the metric data items in the target metric field are processed according to different time intervals;
[0009] According to the processing result, a visual analysis result of the data table is generated.
[0010] In a possible implementation, the processing of the metric data items in the target metric field according to different time intervals based on the time data items in the time dimension field includes:
[0011] The following processing is performed for each set time interval:
[0012] According to the time data items in the time dimension field, the metric data items in the target metric field are divided according to the time interval to obtain a data item grouping of the target metric field corresponding to the time interval;
[0013] A target processing mode corresponding to the target metric field is determined, and the metric data items in the data item group are processed according to the target processing mode.
[0014] In a possible implementation manner, determining the target processing mode corresponding to the target metric field includes:
[0015] Determine the data type and field name of the target metric field;
[0016] Determine the target processing method corresponding to the target metric field according to the data type and field name.
[0017] In a possible implementation, generating a visual analysis result of the data table according to the processing result includes:
[0018] When at least two target metric fields are identified from the data table, the following processing is performed for each set time interval:
[0019] Using the at least two target metric fields and the multiple time periods corresponding to the time interval as a cross-dimensional field group to construct a corresponding data cross-tabulation;
[0020] A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
[0021] In a possible implementation, generating a visual analysis result of the data table corresponding to the time interval according to the data cross table includes:
[0022] Determine a target processing method corresponding to each of the target metric fields;
[0023] In the case where the at least two target metric fields involve at least two of the processing aggregation modes, dividing the processing results of the at least two target metric fields into different data series according to different target processing modes;
[0024] When generating a visualization analysis result of the data table corresponding to the time interval according to the data cross-table, different secondary coordinate axes are used in the visualization analysis result to respectively display different data series.
[0025] In a possible implementation, the method further includes:
[0026] Identifying a target non-time dimension field to be analyzed in the data table;
[0027] Determining a target dimension data item to be analyzed from the target non-time dimension field;
[0028] The processing of the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field includes:
[0029] According to the time data item in the time dimension field, the metric data item corresponding to the target dimension data item in the target metric field is processed according to different time intervals.
[0030] In a possible implementation manner, determining the target dimension data item to be analyzed from the target non-time dimension field includes:
[0031] Determine a target processing method corresponding to the target metric field, and process the metric data item corresponding to each dimensional data item in the target non-time dimension field in the target metric field according to the target processing method;
[0032] sorting the dimension data items in the target non-time dimension field according to the processing result;
[0033] The target dimension data item to be analyzed is determined from the target non-time dimension field according to the sorting result.
[0034] In a possible implementation, generating a visual analysis result of the data table according to the processing result includes:
[0035] The following processing is performed for each set time interval:
[0036] According to the processing result of the metric data item corresponding to the target dimensional data item in the target metric field, the target dimensional data item and multiple time periods corresponding to the time interval are used as a cross-dimensional field group to construct a corresponding data cross-tabulation;
[0037] A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
[0038] In a possible implementation, generating a visual analysis result of the data table according to the processing result includes:
[0039] When at least two target metric fields are identified from the data table, the following processing is performed for each set time interval:
[0040] According to the processing result of the metric data item corresponding to the target dimensional data item in each of the target metric fields, the target dimensional data item and at least two of the target metric fields are used as a cross-dimensional field group to construct a corresponding data cross-tabulation table;
[0041] A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
[0042] In a possible implementation, the processing of the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field is to aggregate the metric data items in the target metric field according to different time intervals;
[0043] When the metric data items in the target metric field are aggregated according to different time intervals, a visual analysis result of the data table is generated according to the aggregation results of the target metric field in the different time intervals.
[0044] In a possible implementation, generating the visual analysis result of the data table according to the aggregation results of the target metric field in the different time intervals includes:
[0045] The following processing is performed for each set time interval:
[0046] Determining, according to an aggregation result of the target metric field in the time interval, month-on-month change information of the target metric field corresponding to the time interval;
[0047] According to the aggregation result of the target metric field in the time interval and the month-on-month change information, a visualization analysis result of the data table corresponding to the time interval is generated.
[0048] In a second aspect, the present application provides a data table processing device, the device comprising:
[0049] Table acquisition module, used to obtain the data table to be processed;
[0050] A field identification module, used to identify the time dimension field and the target metric field to be analyzed in the data table;
[0051] an aggregation module, configured to process the metric data items in the target metric field according to different time intervals based on the time data items in the time dimension field;
[0052] The visualization module is used to generate a visualization analysis result of the data table according to the processing result.
[0053] In a third aspect, the present application provides an electronic device, comprising: a processor and a memory, wherein the processor is used to execute a processing program of a data table stored in the memory to implement the data table processing method described in any one of the first aspects.
[0054] In a fourth aspect, the present application provides a storage medium storing one or more programs, wherein the one or more programs can be executed by one or more processors to implement the data table processing method described in any one of the first aspects.
[0055] The above technical solution provided by the embodiment of the present application has the following advantages over the prior art: the method provided by the embodiment of the present application, by acquiring the data table to be processed, identifies the time dimension field and the target metric field to be analyzed in the data table; according to the time data items in the time dimension field, processes the metric data items in the target metric field according to different time intervals; according to the processing results of the target metric field in the different time intervals, generates a visual analysis result of the data table, and realizes a solution for intelligently processing the metric data according to the time dimension and automatically generating a visual analysis result. In this process, the user does not need to master and set various complex date functions, data aggregation formulas or visualization tools, etc., thereby greatly reducing the threshold and complexity of data analysis, improving the efficiency and accuracy of data analysis, and providing users with a more convenient and intuitive data analysis method. BRIEF DESCRIPTION OF THE DRAWINGS
[0056] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0057] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0058] One or more embodiments are exemplarily described by pictures in the corresponding drawings, and these exemplified descriptions do not constitute limitations on the embodiments. Elements with the same reference numerals in the drawings represent similar elements, and unless otherwise stated, the figures in the drawings do not constitute proportional limitations.
[0059] Figure 1 A flowchart of an embodiment of a method for processing a data table provided in an embodiment of the present application;
[0060] Figure 2 An example of a data table to be processed;
[0061] Figure 3 A schematic diagram for visualizing the analysis results;
[0062] Figure 4A flowchart of another method for processing a data table provided in an embodiment of the present application;
[0063] Figure 5 This is an example of generating a visual analysis result of a data table corresponding to a time interval based on the aggregation result of the target metric field in the time interval and the month-on-month change information;
[0064] Figure 6 Examples of cross-tabulations of data and corresponding visualization charts;
[0065] Figure 7 Another example of a data table to be processed;
[0066] Figure 8 A schematic diagram for visualizing the analysis results;
[0067] Fig. 9 A flowchart of another method for processing a data table provided in an embodiment of the present application;
[0068] Fig.10 Another example of a data table to be processed;
[0069] Fig.11 A schematic diagram for visualizing the analysis results;
[0070] Fig.12 A schematic diagram for visualizing the analysis results;
[0071] Fig.13 A schematic diagram for visualizing the analysis results;
[0072] Fig.14 Another example of a data table to be processed;
[0073] Fig.15 A schematic diagram for visualizing the analysis results;
[0074] Fig.16 A block diagram of an embodiment of a data table processing device provided in an embodiment of the present application;
[0075] Fig.17 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0076] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0077] The disclosure below provides many different embodiments or examples to realize the different structures of the present application. In order to simplify the disclosure of the present application, the parts and settings of specific examples are described below. Of course, they are only examples, and the purpose is not to limit the present application. In addition, the present application can repeat reference numbers and / or letters in different examples. This repetition is for the purpose of simplification and clarity, and does not itself indicate the relationship between the various embodiments and / or settings discussed.
[0078] In order to solve the technical problem that traditional data analysis methods in the prior art have high usage barriers for ordinary users and are difficult to meet users' urgent needs for efficient and accurate data analysis, the present application provides a data table processing method, device, electronic device and storage medium, which can realize a solution for intelligently processing metric data according to the time dimension and automatically generating visual analysis results, greatly reducing the threshold and complexity of data analysis, improving the efficiency and accuracy of data analysis, and providing users with a more convenient and intuitive data analysis method.
[0079] Figure 1 The following is a flow chart of an embodiment of a method for processing a data table provided in an embodiment of the present application. Figure 1 As shown, the process includes the following steps:
[0080] Step 101: Obtain a data table to be processed.
[0081] Step 102: Identify the time dimension field and the target metric field to be analyzed in the data table.
[0082] Generally speaking, the structure of a data table consists of fields and data items. According to the difference in the information carried by the fields, the fields in the data table can be divided into measurement fields and dimension fields. Among them, measurement fields are quantitative fields, which are used to describe quantity or scale. The data types of data items in measurement fields can be numeric values (including integers, decimals, etc.), percentages, etc. The measurement fields in the data table constitute an indispensable quantitative basis for data analysis. Dimension fields play the role of classification and description in the data table, that is, dimension fields are used to classify and describe non-quantitative fields in the data table. The data types of data items in dimension fields can be text (such as region, name, etc.), date (such as year, month, day, quarter, week), etc. According to the data types of data items in dimension fields, the dimension fields in the data table can be divided into time dimension fields and non-time dimension fields. Time dimension fields refer to fields whose data types of data items are time type, which are used to record time information. Time dimension fields constitute the basis for understanding the trend or law of data evolution over time in data analysis. Non-time dimension fields refer to other dimension fields in the data table except time dimension fields.
[0083] In an exemplary embodiment of the present application, the data table to be processed includes at least one time dimension field and one metric field. Figure 2 , which is an example of a data table to be processed. Figure 2 The data table shown includes a time dimension field: statistical time, and multiple measurement fields.
[0084] Exemplarily, in response to a visual analysis instruction triggered by a user on a currently opened data table, the currently opened data table is determined as a data table to be processed.
[0085] Exemplarily, in response to a user inputting a storage path of a data table in a visual analysis tool and triggering a visual analysis instruction for the data table, the data table to be processed is obtained from a designated storage medium according to the storage path input by the user.
[0086] In step 102, the time dimension field and the target metric field to be analyzed are identified in the data table to be processed. First, determine which fields are time dimension fields and which fields are metric fields based on the data types of the fields in the data table to be processed. For example, in the data table to be processed, the fields with a time data type are determined as time dimension fields, and the fields with a numeric or percentage data type are determined as metric fields. Afterwards, the target metric field to be analyzed is selected from the determined metric fields, which means that data analysis is only performed on the target metric field in the future, and other metric fields other than the target metric field are no longer concerned. Here, the target metric field may include one or more, and there is no limitation here.
[0087] In one embodiment, the implementation method of selecting the target metric field to be analyzed from the determined metric field includes: obtaining the table name of the data table to be processed, performing semantic analysis on the table name, which is intended to obtain the information or business scenario contained in the table name, and then intelligently selecting the metric field that best meets the current analysis requirements or business logic from the metric fields contained in the data table according to the semantic analysis results as the target metric field to be analyzed. Among them, semantic analysis can use natural language processing technology, such as lexical analysis, syntactic analysis or a more advanced semantic understanding model, which is not limited here. Exemplarily, a semantic vector of the table name and each metric field is generated, and the semantic vector of the table name is respectively calculated with the semantic vector of each metric field for similarity, and the metric field with the highest similarity or ranked in the top N is selected as the target metric field to be analyzed. N is a natural number greater than 1. Exemplarily, N is a set value, or a value determined according to the number of metric fields in the data table. For example, N = int (p × s), s is the number of metric fields in the data table, p is a preset value greater than 0 and less than 1, and int () means rounding down.
[0088] Step 103: According to the time data items in the time dimension field, the metric data items in the target metric field are processed according to different time intervals.
[0089] Step 104: Generate a visual analysis result of the data table according to the processing results of the target metric field in different time intervals.
[0090] The different time intervals include at least two of the following time intervals: day, week, month, quarter, year, and other user-defined time periods (such as the last week, the last two weeks, the last 30 days, etc.).
[0091] In one implementation, based on the time data items in the time dimension field, the metric data items in the target metric field are processed according to different time intervals, so that the metric data items in the target metric field are aggregated according to different time intervals; when the metric data items in the target metric field are aggregated according to different time intervals, a visual analysis result of the data table is generated according to the aggregation results of the target metric field in different time intervals.
[0092] Taking aggregation processing as an example, the aggregation processing method can be summing, averaging, maximum / minimum value or more complex statistical operations. The specific processing method depends on the analysis requirements and business logic, and is not limited here.
[0093] Taking aggregation processing as an example, in step 103, the execution subject of the embodiment of the present application aggregates the metric data items in the target metric field according to different time intervals based on the time data items in the time dimension field. Figure 1 In the example data table, it is assumed that the "Start Proofreading PV" field is determined as the target metric field, and it is assumed that the time intervals to be aggregated include: monthly and quarterly. Then, in step 103, the execution subject of the embodiment of the present application will aggregate the metric data items in the "Start Proofreading PV" field by month and quarter respectively according to the time data items in the "Statistical Time" field, and obtain the sum value of the "Start Proofreading PV" corresponding to different months, and the sum value of the "Start Proofreading PV" corresponding to different quarters.
[0094] Next, in step 104, the execution subject of the embodiment of the present application generates a visual analysis result of the data table according to the aggregation result of the target metric field in different time intervals. Exemplarily, the visual analysis result of the data table includes but is not limited to: the aggregation result of the target metric field in different time intervals, the interpretation data generated based on the aggregation result of the target metric field in different time intervals, the interpretation data generated based on the aggregation result of the target metric field in a certain time interval, and so on. The interpretation data is the derivative data obtained after the in-depth interpretation and analysis of the aggregation result, such as the growth rate, the month-on-month change, the year-on-year change and other data. By interpreting the data, the reasons and trends of the changes in the target metric field can be more deeply revealed, thereby providing more powerful data support for user decision-making. In an exemplary scheme, a trained artificial intelligence model can be used to interpret and analyze the aggregation results in depth to obtain the interpretation data, which is not limited here. The presentation form of the visual analysis result includes but is not limited to: a combination of one or more forms of data tables, visual charts, text reports and the like. Among them, the visual chart can be in the form of a chart, a curve chart, a bar chart, a pie chart, etc., and the specific form can depend on the characteristics of the data and the target of the analysis, which is not limited here.
[0095] For example, see Figure 3 ,for Figure 1 The following is a diagram of the visual analysis results of the data table in the above example scenario. Figure 3 It can be seen that users can easily obtain the aggregated results of "Start Proofreading PV" in different time intervals (such as daily and monthly), and interpret the data to better understand the distribution of the data and its changing trends over time.
[0096] The technical solution provided by the embodiment of the present application obtains a data table to be processed, identifies a time dimension field and a target metric field to be analyzed in the data table; processes the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field; generates a visual analysis result of the data table according to the processing results of the target metric field in the different time intervals, thereby realizing a solution for intelligently processing the metric data in the data table according to the time dimension and automatically generating a visual analysis result. In this process, the user does not need to master and set various complex date functions, data aggregation formulas or visualization tools, etc., thereby greatly reducing the threshold and complexity of data analysis, improving the efficiency and accuracy of data analysis, and providing users with a more convenient and intuitive data analysis method.
[0097] Figure 4 A flowchart of another method for processing a data table provided in an embodiment of the present application. Figure 4 The process shown in Figure 1Based on the process shown in FIG. 1 , the exemplary implementation process of processing the measurement data items in the target measurement field according to different time intervals according to the time data items in the time dimension field is described in detail. Figure 4 As shown, the following steps are included:
[0098] Step 401: Obtain a data table to be processed.
[0099] Step 402: Identify the time dimension field and the target metric field to be analyzed in the data table.
[0100] For a detailed description of step 401 and step 402, see the above Figure 1 The relevant descriptions in the process shown will not be repeated here.
[0101] Step 403, obtain the set time interval, and perform the following processing for each set time interval: according to the time data items in the time dimension field, divide the metric data items in the target metric field according to the time interval to obtain the data item grouping of the target metric field corresponding to the time interval.
[0102] Step 404: determine a target processing method corresponding to the target metric field, and process the metric data items in the data item group according to the target processing method.
[0103] pass Figure 2 As can be seen from the example, each metric data item in the target metric field has a corresponding time data item in the time dimension field to represent the time information of the metric data item. Then, for each set time interval, according to the time data item in the time dimension field, the metric data items in the target metric field are divided according to the time interval to obtain the data item grouping corresponding to the time interval in the target metric field.
[0104] For example, when the set time interval is monthly, the metric data items in the target metric field are divided by month, the metric data items in the same month are divided into the same data item group, and the metric data items in different months are divided into different data item groups. Finally, multiple data item groups are obtained, each of which corresponds to a month.
[0105] For another example, when the set time interval is quarter, the metric data items in the target metric field are divided by quarter, the metric data items in the same quarter are divided into the same data item group, and the metric data items in different quarters are divided into different data item groups. Finally, multiple data item groups are obtained, each corresponding to a quarter.
[0106] For another example, when the set time interval is a year, the metric data items in the target metric field are divided by year, the metric data items in the same year are divided into the same data item group, and the metric data items in different years are divided into different data item groups. Finally, multiple data item groups are obtained, each corresponding to a year.
[0107] Then, in step 404, the target processing method corresponding to the target metric field is determined, and the metric data items in each data item group are processed respectively according to the target processing method. For example, taking aggregation processing as an example, if the target processing method is summation, the metric data items in the data item groups of different months are summed up respectively to obtain the sum value of the target metric field corresponding to different months. The aggregation result (i.e., the processing result) here can be seen in Figure 3 .
[0108] In one embodiment, the specific implementation of determining the target aggregation method corresponding to the target metric field includes: determining the data type and field name of the target metric field, and determining the target processing method corresponding to the target metric field based on the data type and field name.
[0109] Among them, numeric fields are usually suitable for summing, while percentage fields are usually suitable for averaging. Therefore, the target processing method corresponding to the target metric field can be determined by the data type.
[0110] In addition, field names can also be used as a basis for determining the target processing method. Field names usually contain clear information about the meaning and purpose of the field, which can help the system more accurately determine the applicable processing method. For example, you can analyze whether the field name contains specific keywords, such as "total", "average", "maximum", "minimum", etc. These keywords are often associated with specific processing methods. For example, fields with "total" in the field name are usually suitable for summation processing, while fields with "average" may be suitable for averaging processing. For another example, natural language processing technology can be used to perform semantic analysis on field names. By analyzing the meaning and context of field names, the system can further determine the applicable processing method. For example, for the field name "monthly sales", the system can determine that the field is suitable for monthly summation processing.
[0111] Based on this, the data type and field name of the target metric field are determined, and the target processing method corresponding to the target metric field is determined based on the data type and field name. This method can more accurately determine the target processing method applicable to the target metric field.
[0112] Figure 4The embodiment shown in the figure divides the metric data items in the target metric field according to the time interval according to the time data items in the time dimension field, obtains the data item grouping corresponding to the time interval of the target metric field, aggregates the metric data in the data item grouping, and generates a visual analysis result of the data table according to the aggregation processing result, thus realizing a solution of intelligently processing the metric data in the data table according to the time dimension and automatically generating a visual analysis result. At the same time, Figure 4 In the illustrated embodiment, the target processing method corresponding to the target metric field can be intelligently determined during processing, which eliminates the need for users to master and set up complex data processing formulas, thereby greatly reducing the threshold and complexity of data analysis, improving the efficiency and accuracy of data analysis, and providing users with a more convenient and intuitive data analysis method.
[0113] In practical applications, especially in scenarios where data trends over time are analyzed, month-on-month growth is a common and important analysis dimension. It provides an intuitive way to compare changes in data between two time periods, and is used to reveal the growth or decline of data between the two time periods. Month-on-month growth is usually expressed as a percentage or ratio, and is calculated as follows:
[0114] Month-on-month change rate = (current period value - previous period value) / previous period value * 100%
[0115] Accordingly, in one implementation, the specific implementation of generating the visualization analysis results of the data table according to the processing results of the target metric field in different time intervals may include: performing the following processing for each set time interval: determining the month-on-month change information of the target metric field corresponding to the time interval according to the aggregation result of the target metric field in the time interval, and then generating the visualization analysis results of the data table corresponding to the time interval according to the processing results of the target metric field in the time interval and the month-on-month change information. The month-on-month change information includes the month-on-month change rate of the processing results of the target metric field in two consecutive time periods.
[0116] Taking the monthly aggregation of the metric data items in the target metric field "Start Proofreading PV" as an example, the month-on-month change rate of the sum of "Start Proofreading PV" between each two consecutive months can be calculated according to the above formula for calculating the month-on-month change rate. For example, it includes the month-on-month change rate of "Start Proofreading PV" in July compared to June, the month-on-month change rate in August compared to July, the month-on-month change rate in September compared to August, and so on.
[0117] See also Figure 5 , which is an example of generating a visual analysis result of a data table corresponding to a time interval based on the aggregation result of the target metric field in the time interval and the month-on-month change information.
[0118] Figure 5 In the example, the sum of the metric field "Start Proofreading PV" for each month from June to September is presented in the form of a bar chart, and the month-on-month change information of the sum of the metric field "Start Proofreading PV" from June to September is presented in the form of a curve. The left vertical axis corresponds to the "sum" and the right vertical axis corresponds to the "month-on-month change rate". In addition, Figure 5 As shown, corresponding interpretation data can also be generated based on the month-on-month change information, for example, "the month-on-month data from June to September showed that the startup proofreading PV fluctuated between growth and decline, with the maximum increase of 69.11% and the maximum decrease of 82.74%."
[0119] pass Figure 5 It can be seen from the example that the visual analysis results of the data table obtained by applying the embodiments of the present application integrate multiple analysis results displayed in multiple forms. This method enriches the data presentation method, improves the depth and breadth of data analysis, and also enhances the user's intuitiveness and convenience in understanding the data.
[0120] In addition, when the time span involved in the target metric field exceeds 1 year, for the monthly aggregation method, the year and month are concatenated as the time dimension of the aggregation. For example, the metric data items for January 2024 are divided into one data item group, and the metric data items for January 2023 are divided into another data item group, and then the metric data items in the two data item groups are processed separately (for example, aggregation processing), and the aggregation results of the target metric field in January 2024 and the aggregation results of the target metric field in January 2023 are obtained.
[0121] Similarly, when the time span involved in the target metric field exceeds 1 year, for the quarterly aggregation method, the year and quarter are concatenated as the time dimension of the aggregation. For example, the metric data items corresponding to the months included in the first quarter of 2024 are divided into one data item group, and the metric data items corresponding to the months included in the first quarter of 2023 are divided into another data item group, and then the metric data items in the two data item groups are processed separately (for example, aggregation processing), and the aggregation results of the target metric field in the first quarter of 2024 and the aggregation results of the target metric field in the first quarter of 2023 are obtained.
[0122] In one embodiment, combined with the "month-on-month" definition described above, when the time span involved in the target metric field exceeds 1 year, the time dimension can be further split into two dimensions: year and month, or year and quarter, and a data cross table is generated with the corresponding aggregation results as values. Based on the data cross table, the month-on-month change rate of the same month or quarter in two consecutive years can be calculated. Further, a visual chart, such as a bar chart or a line chart, can be generated based on the data cross table.
[0123] For example, see Figure 6 , which is an example of a data crosstab and the corresponding visualization chart. Figure 6 In the data crosstab shown in the example, year is used as the column dimension and month is used as the row dimension. Figure 6 The month-on-month growth rate refers to the month-on-month change rate between 2022 and the same month in 2021.
[0124] The above is a comprehensive explanation of the processing method of the data table provided in the embodiment of the present application in combination with specific examples. In the above specific example, only one target metric field is included. However, in actual applications, there are also cases where more than one target metric field is included. In view of this situation, the present application provides the following exemplary embodiments:
[0125] In one embodiment, when at least two target metric fields are identified from a data table, an exemplary implementation of generating a visual analysis result of the data table based on the processing results of the target metric fields in different time intervals includes: for each set time interval, using at least two target metric fields and multiple time periods corresponding to the time interval as a cross-dimensional field group to construct a corresponding data cross-tabulation; and generating a visual analysis result of the data table corresponding to the time interval based on the data cross-tabulation.
[0126] The multiple time periods corresponding to the time interval refer to the time periods corresponding to each data item group obtained by dividing the measurement data items in the target measurement field according to the time interval. For example, assuming that the measurement data items in the target measurement field are divided according to the month, 4 data item groups are obtained, and the 4 data item groups correspond to June, July, August, and September respectively. Then, the time period corresponding to the monthly time interval includes June, July, August, and September.
[0127] Using at least two target metric fields and multiple time periods corresponding to the time interval as a cross-dimensional field group to construct a corresponding data cross table means: using the target metric fields and time periods as rows and columns respectively, and the intersection of the rows and columns is: the processing result of a certain target metric field in a certain time period.
[0128] Afterwards, a data table is generated based on the data cross-tab to generate visual analysis results corresponding to the time interval.
[0129] Furthermore, in practical applications, different target metric fields may use different target processing methods. For example, the target processing method corresponding to some target metric fields is summation, while the target processing method corresponding to other target metric fields is averaging. For different processing methods, the metric attributes (such as measurement units, order of magnitude) of the processing results are usually different. Therefore, when integrating different target metric fields to obtain a unified visual analysis result, the problem is how to clearly display the processing results of different target metric fields.
[0130] In this regard, the following embodiments are provided: an exemplary implementation of generating a visual analysis result of a data table corresponding to a time interval based on a data cross-tabulation includes: determining a target processing method corresponding to each target metric field; in a case where at least two target metric fields involve at least two target processing methods, dividing the processing results of the at least two target metric fields into different data series according to different target processing methods; when generating a visual analysis result of a data table corresponding to the time interval based on the data cross-tabulation, different secondary coordinate axes are used in the visual analysis result to display different data series respectively.
[0131] By using different secondary coordinate axes to display different data series respectively, the distribution or change trend of the data in these data series can be displayed more clearly, and these data series can be prevented from overlapping or confusing each other on the primary coordinate axis. Here, the primary coordinate axis is, for example, multiple time periods under a time interval.
[0132] To facilitate understanding, the following explanation is given with specific examples:
[0133] See also Figure 7 , which is another example of a data table to be processed. Figure 7 The data table shown includes a time dimension field: "Statistical Time", and 6 measurement fields.
[0134] Assume that Figure 7 The six metric fields in the data table shown are all identified as target metric fields to be analyzed. According to the description of the above embodiment, first, for each target metric field, the metric data items in the target metric field are processed (e.g., aggregated) according to different time intervals according to the time data items in the time dimension field, and the aggregated results of the target metric field in different time intervals are obtained. Figure 7 In the example, for each target metric field, the aggregation result of the target metric field in the quarterly interval is obtained. Assume that the quarterly interval includes four time periods: Q3 2023, Q4 2023, Q1 2024, and Q2 2024.
[0135] According to the above description, the data cross table shown in Table 1 below can be constructed:
[0136] Table 1
[0137] 2023Q3 2023Q4 2024Q1 2024Q2 Application Function A Aggregate results Aggregate results Aggregate results Aggregate results Successfully entered the function Aggregate results Aggregate results Aggregate results Aggregate results Successfully entered function A Aggregate results Aggregate results Aggregate results Aggregate results ... ... ... ... ...
[0138] The above Table 1 is only an example of a data crosstab that is constructed by using at least two target metric fields and multiple time periods corresponding to the time interval as a cross-dimensional field group. In actual applications, the time periods can also be placed in the rows of the data crosstab and the metric fields can be placed in the columns of the data crosstab. The embodiments of the present application do not limit this.
[0139] Afterwards, assuming Figure 7 Among the six metric fields in the example, the target processing methods for the four metric fields "Application Function A", "Successful Entry into Function A", "Successful Entry into Function" and "Click Entry" are summation, and the target processing methods for the other two metric fields are averaging. Then, the aggregation results of the six metric fields are divided into two data series according to the different target processing methods. Afterwards, when generating the visualization analysis results of the data table corresponding to the time interval according to the data cross table shown in Table 1, different secondary coordinate axes are used in the visualization analysis results to display different data series. For example, see Figure 8 In the example of , the right vertical axis corresponds to the measurement of the processing result obtained by the average processing method, and the left vertical axis corresponds to the measurement of the processing result obtained by the summation aggregation method. Figure 8 In the visualization, different target measurement fields are displayed in different colors to make the visual analysis results clearer and more intuitive.
[0140] pass Figure 8 It can be seen from the example that when there is more than one target metric field in the data table, the technical solution provided in the embodiment of the present application can be applied to clearly compare and present the analysis results of different target metric fields in the visual analysis results. This presentation method helps users to have a more comprehensive understanding of the business status and discover potential needs, thereby providing more accurate data support for users to make decisions.
[0141] In the above embodiments and specific examples, only the processing of the time dimension field and at least one target metric field is involved. In practical applications, in addition to the time dimension field, non-time dimension fields are often present in the data table. In view of this situation, the present application provides the following exemplary embodiments:
[0142] See also Fig. 9 , which is a flow chart of an embodiment of another data table processing method provided in an embodiment of the present application. Fig. 9 The process shown in the above Figure 1Based on the process shown, the following steps are included:
[0143] Step 901: Obtain a data table to be processed.
[0144] Step 902: Identify in the data table the time dimension field, the target metric field to be analyzed, and the target non-time dimension field to be analyzed.
[0145] When the target non-time dimension fields to be analyzed are identified from the data table to be processed, first determine which fields are non-time dimension fields based on the data types of the fields in the data table to be processed. For example, in the data table to be processed, the fields whose data types are non-time types and non-numeric types such as numeric values and percentages are determined as non-time dimension fields. Afterwards, the target non-time dimension fields to be analyzed are selected from the determined non-time dimension fields. This means that data analysis will only be performed on the target non-time dimension fields in the future, and other non-time dimension fields other than the target non-time dimension fields will no longer be concerned. Here, the target non-time dimension fields may include one or more, and there is no limitation here.
[0146] In one embodiment, the implementation method of selecting the target non-time dimension field to be analyzed from the determined non-time dimension fields includes: obtaining the table name of the data table to be processed, performing semantic analysis on the table name, which is intended to obtain the information or business scenario contained in the table name, and then intelligently selecting the non-time dimension field that best meets the current analysis requirements or business logic from the non-time dimension fields contained in the data table according to the semantic analysis results as the target non-time dimension field to be analyzed. Among them, semantic analysis can utilize natural language processing technology, such as lexical analysis, syntactic analysis, or a more advanced semantic understanding model, which is not limited here. Exemplarily, a semantic vector of the table name and each non-time dimension field is generated, and the semantic vector of the table name is respectively calculated for similarity with the semantic vector of each non-time dimension field, and the non-time dimension field with the highest similarity or ranked in the top M is selected as the target non-time dimension field to be analyzed. M is a natural number greater than 1. Exemplarily, M is a set value, or a value determined according to the number of non-time dimension fields in the data table, for example, M=int(p×T), T is the number of non-time dimension fields in the data table, p is a preset value greater than 0 and less than 1, and int() means rounding down.
[0147] Step 903: Determine the target dimension data item to be analyzed from the target non-time dimension field.
[0148] In one embodiment, the target dimension data items to be analyzed include some data items in the target non-time dimension field. In practical applications, the some data items are usually relatively important data items, or data items that can make key contributions.
[0149] An exemplary implementation of determining the target dimension data items to be analyzed from the target non-time dimension field includes: determining the target processing method corresponding to the target metric field, processing each dimension data item in the target non-time dimension field according to the target processing method and the corresponding metric data item in the target metric field; sorting the dimension data items in the target non-time dimension field according to the processing results; and determining the target dimension data items to be analyzed from the target non-time dimension field according to the sorting results.
[0150] In one embodiment of the present application, taking aggregation processing as an example, the target aggregation processing mode corresponding to the target metric field is determined, and each dimension data item in the target non-time dimension field is processed in the corresponding metric data item in the target metric field according to the target aggregation processing mode; wherein optionally, the larger the value of the default aggregation result is, the more important the dimension data item is. Therefore, the above-mentioned sorting of the dimension data items in the target non-time dimension field according to the aggregation result can be: sorting the dimension data items in the target non-time dimension field in order from large to small according to the value of the aggregation result. Determining the target dimension data items to be analyzed from the target non-time dimension field according to the sorting result can be: determining some dimension data items in the front as the target dimension data items to be analyzed according to the sorting result. The specific selection number can be a preset value, or it can be a value set according to the total number of dimension data items in the target non-time dimension field. For example, when the total number of dimension data items is greater than 50, the dimension data items ranked in the top 10 are selected as the target dimension data items. When the total number of dimension data items is less than or equal to 6, all dimension data items are selected as the target dimension data items.
[0151] Step 904: Based on the time data item in the time dimension field, the metric data item corresponding to the target dimension data item in the target metric field is processed according to different time intervals.
[0152] Step 905: Generate a visual analysis result of the data table according to the processing results of the target dimension data item corresponding to the metric data item in the target metric field in different time intervals.
[0153] In one embodiment, an exemplary implementation of generating visual analysis results of a data table based on processing results of a target metric field in different time intervals includes: for each set time interval, based on the processing results of the metric data items corresponding to the target dimensional data items in the target metric field, constructing a corresponding data cross-tabulation using the target dimensional data items and multiple time periods corresponding to the time interval as a cross-dimensional field group; constructing a corresponding data cross-tabulation using at least two target metric fields and multiple time periods corresponding to the time interval as a cross-dimensional field group; and generating visual analysis results of the data table corresponding to the time interval based on the data cross-tabulation.
[0154] For ease of understanding, steps 901 to 905 are explained below with reference to specific examples:
[0155] See also Fig.10 , which is another example of a data table to be processed. Fig.10 The data table shown includes one time dimension field: "Archive Date", one measurement field: "Total Actual Received Payments", and four non-time dimension fields.
[0156] Assume that Fig.10 The "store" field in the data table shown is identified as the target non-time dimension field to be analyzed. Afterwards, according to the description of step 903, the target dimension data items to be analyzed are determined from the "store" field target, assuming that the four target dimension data items are "Shi*he Old Hall", "Ju*bei Store", "Shi*he Hall" and "Jin* Store". Afterwards, according to the description in step 904, based on the time data items in the time dimension field, the metric data items corresponding to the four target dimension data items in the target metric field are processed according to different time intervals (e.g., aggregated). For example, for Fig.10 In the example of , for each target dimension data item, the aggregation results of the target dimension data item on 2016-7-6, 2016-7-7, 2016-7-8, etc. are obtained.
[0157] According to the above description, the data cross table shown in Table 2 below can be constructed:
[0158] Table 2
[0159] Shi*he Old House Ju*Beidian Ten*River House Gold store 2016-7-6 Aggregate results Aggregate results Aggregate results Aggregate results 2016-7-7 Aggregate results Aggregate results Aggregate results Aggregate results 2016-7-8 Aggregate results Aggregate results Aggregate results Aggregate results ... ... ... ... ...
[0160] After that, according to the data cross table shown in Table 2, select the appropriate visualization chart type, such as a column chart, bar chart, line chart, pie chart, etc., to generate visualization analysis results. Fig.11 Visual analysis results of the example.
[0161] pass Fig.11It can be seen from the example that, when there is a non-time dimension field in the data table, the technical solution provided by the embodiment of the present application can be applied to clearly compare and present the analysis results of different non-time dimension data items under the same measurement field in the visual analysis results. This presentation method helps users to intuitively understand the differences and trends between different non-time dimension data items.
[0162] In one embodiment, according to Fig. 9 In the process of determining the target dimension data item to be analyzed from the target non-time dimension field in the illustrated embodiment, the analysis process can also be displayed and output as a visual analysis result of the data table. Fig.12 In the example, the processing results of the corresponding metric data items in the target metric field for each dimensional data item in the target non-time dimension field are displayed in the form of a bar chart, and are displayed in order according to the above sorting results. This processing method helps users intuitively understand the differences and trends between different non-time dimension data items.
[0163] In one embodiment, see Fig.12 For example, the contribution of the dimension data items can also be defined according to the sorting results of the dimension data items in the target non-time dimension field. For example, three contribution levels are pre-set: low, medium, and high. According to the sorting results, the contribution levels of the top few items are determined to be high, the contribution levels of the bottom few items are determined to be low, and the contribution levels of the middle few items are determined to be medium. As for the definition of the specific division values, a preset value can be adopted, or it can be determined according to the total number of dimension data items in the target non-time dimension field. For example, when the total number of dimension data items in the target non-time dimension field is less than or equal to 6, no classification is performed. When the number of dimension data items in the target non-time dimension field is greater than 6 and less than 50, they are classified according to the three levels of low, medium, and high, and the top 10 are defined as high contribution, the bottom 10 are defined as low contribution, and the rest are defined as high contribution.
[0164] Furthermore, in the visual analysis results, interpretation data on the contribution of dimensional data items are presented to facilitate users' intuitive understanding and improve user experience.
[0165] In one embodiment, when a target non-time dimension field to be analyzed is identified from a data table, the month-on-month analysis method proposed in the above embodiment is also applicable.
[0166] For example, an exemplary implementation of generating a visual analysis result of a data table according to the processing results of the metric data item corresponding to the target dimension data item in the target metric field in different time intervals includes: for each set time interval, according to the processing results of the metric data item corresponding to the target dimension data item in the target metric field in the time interval, determining the month-on-month change information of the target dimension data item corresponding to the time interval, and then generating a visual analysis result of the data table corresponding to the time interval according to the processing results of the metric data item corresponding to the target dimension data item in the target metric field in the time interval and the month-on-month change information. The month-on-month change information includes the month-on-month change rate of the processing results of the target dimension data item in two consecutive time periods.
[0167] For example, see Fig.13 The example includes the total sales amount of different specialty stores in July and August, and presents the processing result in the form of a bar chart: the total sales amount. At the same time, the month-on-month change rate of the total sales amount of each specialty store between July and August is calculated, and the month-on-month change amount is presented in the form of a curve in the chart. Among them, the left vertical axis corresponds to "sum" and the right vertical axis corresponds to "month-on-month change rate". In addition, if Fig.13 As shown, corresponding interpretation data can also be generated based on the month-on-month change rate, such as "analyzing 9 specialty stores, the sales amount in August decreased by 93.85% compared with July, an overall decline."
[0168] pass Fig.13 It can be seen from the example that the visual analysis results of the data table obtained by applying the embodiments of the present application integrate multiple analysis results displayed in multiple forms. This method enriches the data presentation method, improves the depth and breadth of data analysis, and also enhances the user's intuitiveness and convenience in understanding the data.
[0169] In actual applications, there are also cases where the data table contains a time dimension field, a non-time dimension segment, and more than one target metric field. In view of this situation, the present application provides the following exemplary embodiments:
[0170] In one embodiment, an exemplary implementation of generating visual analysis results of a data table based on processing results of target metric fields in different time intervals includes: when at least two target metric fields are identified from the data table, performing the following processing for each set time interval: based on the processing results of the metric data items corresponding to the target dimension data items in each target metric field, constructing a corresponding data cross-tabulation using the target dimension data items and at least two target metric fields as a cross-dimensional field group; and generating visual analysis results of the data table corresponding to the time interval based on the data cross-tabulation.
[0171] For ease of understanding, the embodiment is explained below with reference to specific examples:
[0172] See also Fig.14 , which is another example of a data table to be processed. Fig.14 The data table shown includes a time dimension field: Sales Date, multiple measure fields, and multiple non-time dimension fields.
[0173] Assume that Fig.14 The "Major Product Category" field in the data table shown is identified as the target non-time dimension field to be analyzed, and the "Total Cost of Goods" and "Total Sales" therein are identified as the target metric fields to be analyzed. Afterwards, according to the description of step 903, the target dimension data items to be analyzed are determined from the "Major Product Category" field, assuming that the four target dimension data items include "TV", "Refrigerator", "Washing Machine" and "Mobile Phone". Thereafter, according to the description in step 904, based on the time data items in the time dimension field, the metric data items corresponding to the four target dimension data items in the target metric field are processed according to different time intervals (e.g., aggregation processing). For example, for Fig.14 In the example, for each target dimension data item, the aggregation result of the target dimension data item in the recent period (such as the past month, the past seven days, the past day, etc.) is obtained, including the total cost of goods and the total sales amount.
[0174] According to the above description, the data cross table shown in Table 3 below can be constructed:
[0175] Table 3
[0176] Product categories Total cost of goods Total sales television Aggregate results Aggregate results air conditioner Aggregate results Aggregate results refrigerator Aggregate results Aggregate results cell phone ... ...
[0177] After that, according to the data cross table shown in Table 3, select the appropriate visualization chart type, such as a column chart, bar chart, line chart, pie chart, etc., to generate visualization analysis results. Fig.15 Visual analysis results of the example.
[0178] pass Fig.15 It can be seen from the example that, in the case where there are multiple target measurement fields corresponding to non-time dimension fields in the data table, the technical solution provided by the embodiment of the present application can be applied to clearly compare and present the analysis results of the same non-time dimension data item under different measurement fields in the visual analysis results. This presentation method helps users to intuitively understand the performance of different measurement fields, and enhances the intuitiveness and convenience of users' understanding of data.
[0179] Fig.16 This is a block diagram of an embodiment of a data table processing device provided in an embodiment of the present application. Fig.16 As shown, the device comprises:
[0180] Table acquisition module 1601, used to acquire a data table to be processed;
[0181] A field identification module 1602 is used to identify a time dimension field and a target metric field to be analyzed in the data table;
[0182] Aggregation module 1603, used for processing the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field;
[0183] The visualization module 1604 is used to generate a visualization analysis result of the data table according to the processing result.
[0184] In a possible implementation, the aggregation module 1603 includes:
[0185] A grouping unit, configured to perform the following processing for each set time interval: according to the time data items in the time dimension field, divide the metric data items in the target metric field according to the time interval to obtain a data item group of the target metric field corresponding to the time interval;
[0186] The aggregation unit is used to determine the target processing mode corresponding to the target metric field, and process the metric data items in the data item group according to the target processing mode.
[0187] In a possible implementation, the polymerization unit is specifically used for:
[0188] Determine the data type and field name of the target metric field;
[0189] Determine the target processing method corresponding to the target metric field according to the data type and field name.
[0190] In a possible implementation, the visualization module 1604 is specifically configured to:
[0191] When at least two target metric fields are identified from the data table, the following processing is performed for each set time interval:
[0192] Using the at least two target metric fields and the multiple time periods corresponding to the time interval as a cross-dimensional field group to construct a corresponding data cross-tabulation;
[0193] A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
[0194] In a possible implementation, the visualization module 1604 is specifically configured to:
[0195] Determine a target processing method corresponding to each of the target metric fields;
[0196] In a case where the at least two target metric fields involve at least two of the target processing modes, dividing the processing results of the at least two target metric fields into different data series according to different target processing modes;
[0197] When generating a visualization analysis result of the data table corresponding to the time interval according to the data cross-table, different secondary coordinate axes are used in the visualization analysis result to respectively display different data series.
[0198] In a possible implementation manner, the field identification module is further used to:
[0199] Identifying a target non-time dimension field to be analyzed in the data table;
[0200] Determining a target dimension data item to be analyzed from the target non-time dimension field;
[0201] The aggregation module 1603 is specifically used for:
[0202] According to the time data items in the time dimension field, the metric data items corresponding to the target dimensional data items in the target metric field are aggregated according to different time intervals.
[0203] In a possible implementation manner, the field identification module is specifically used to:
[0204] Determine a target processing method corresponding to the target metric field, and perform aggregation processing on each dimensional data item in the target non-time dimension field and the corresponding metric data item in the target metric field according to the target processing method;
[0205] sorting the dimension data items in the target non-time dimension field according to the processing result;
[0206] The target dimension data item to be analyzed is determined from the target non-time dimension field according to the sorting result.
[0207] In a possible implementation, the visualization module 1604 is specifically configured to:
[0208] The following processing is performed for each set time interval:
[0209] According to the processing result of the metric data item corresponding to the target dimensional data item in the target metric field, the target dimensional data item and multiple time periods corresponding to the time interval are used as a cross-dimensional field group to construct a corresponding data cross-tabulation;
[0210] Using the at least two target metric fields and the multiple time periods corresponding to the time interval as a cross-dimensional field group to construct a corresponding data cross-tabulation;
[0211] A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
[0212] In a possible implementation, the visualization module 1604 is specifically configured to:
[0213] When at least two target metric fields are identified from the data table, the following processing is performed for each set time interval:
[0214] According to the processing result of the metric data item corresponding to the target dimensional data item in each of the target metric fields, the target dimensional data item and at least two of the target metric fields are used as a cross-dimensional field group to construct a corresponding data cross-tabulation table;
[0215] A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
[0216] In a possible implementation, the processing of the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field is to aggregate the metric data items in the target metric field according to different time intervals;
[0217] When the metric data items in the target metric field are aggregated according to different time intervals, a visual analysis result of the data table is generated according to the aggregation results of the target metric field in the different time intervals.
[0218] In a possible implementation, the visualization module 1604 is specifically configured to:
[0219] The following processing is performed for each set time interval:
[0220] Determining, according to an aggregation result of the target metric field in the time interval, month-on-month change information of the target metric field corresponding to the time interval;
[0221] According to the aggregation result of the target metric field in the time interval and the month-on-month change information, a visualization analysis result of the data table corresponding to the time interval is generated.
[0222] like Fig.17As shown, an embodiment of the present application provides an electronic device, including a processor 111, a communication interface 112, a memory 113 and a communication bus 114, wherein the processor 111, the communication interface 112, and the memory 113 communicate with each other through the communication bus 114.
[0223] A memory 113, for storing computer programs;
[0224] In one embodiment of the present application, the processor 111 is used to implement the data table processing method provided by any one of the aforementioned method embodiments when executing the program stored in the memory 113, including:
[0225] Get the data table to be processed;
[0226] Identifying a time dimension field and a target metric field to be analyzed in the data table;
[0227] According to the time data items in the time dimension field, the metric data items in the target metric field are processed according to different time intervals;
[0228] According to the processing result, a visual analysis result of the data table is generated.
[0229] An embodiment of the present application further provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the steps of the data table processing method provided in any of the aforementioned method embodiments are implemented.
[0230] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0231] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a general hardware platform, and of course, by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the relevant technology can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.
[0232] It should be understood that the terms used in the text are only for the purpose of describing specific example embodiments, and are not intended to be limiting. Unless the context clearly indicates otherwise, the singular forms "one", "an" and "said" as used in the text may also be meant to include plural forms. The terms "include", "comprise", "contain", and "have" are inclusive, and therefore specify the existence of stated features, steps, operations, elements and / or parts, but do not exclude the existence or addition of one or more other features, steps, operations, elements, parts, and / or combinations thereof. The method steps, processes, and operations described herein are not interpreted as necessarily requiring them to be performed in the specific order described or illustrated, unless the execution order is clearly indicated. It should also be understood that additional or alternative steps may be used.
[0233] The above description is only a specific implementation of the present application, so that those skilled in the art can understand or implement the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest range consistent with the principles and novel features applied for herein.
Claims
1. A method for processing a data table, characterized in that: The method comprises: Get the data table to be processed; Identifying a time dimension field and a target metric field to be analyzed in the data table; According to the time data items in the time dimension field, the metric data items in the target metric field are processed according to different time intervals; According to the processing result, a visual analysis result of the data table is generated.
2. The method according to claim 1, characterized in that The processing of the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field includes: The following processing is performed for each set time interval: According to the time data items in the time dimension field, the metric data items in the target metric field are divided according to the time interval to obtain a data item grouping of the target metric field corresponding to the time interval; A target processing mode corresponding to the target metric field is determined, and the metric data items in the data item group are processed according to the target processing mode.
3. The method according to claim 2, characterized in that The determining of the target processing mode corresponding to the target metric field includes: Determine the data type and field name of the target metric field; Determine the target processing method corresponding to the target metric field according to the data type and field name.
4. The method according to claim 1, characterized in that: Generating a visual analysis result of the data table according to the processing result includes: When at least two target metric fields are identified from the data table, the following processing is performed for each set time interval: Using the at least two target metric fields and the multiple time periods corresponding to the time interval as a cross-dimensional field group to construct a corresponding data cross-tabulation; A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
5. The method according to claim 4, characterized in that Generating a visual analysis result of the data table corresponding to the time interval according to the data cross table includes: Determine a target processing method corresponding to each of the target metric fields; In a case where the at least two target metric fields involve at least two of the target processing modes, dividing the processing results of the at least two target metric fields into different data series according to different target processing modes; When generating a visualization analysis result of the data table corresponding to the time interval according to the data cross-table, different secondary coordinate axes are used in the visualization analysis result to respectively display different data series.
6. The method according to claim 1, characterized in that The method further comprises: Identifying a target non-time dimension field to be analyzed in the data table; Determining a target dimension data item to be analyzed from the target non-time dimension field; The processing of the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field includes: According to the time data item in the time dimension field, the metric data item corresponding to the target dimension data item in the target metric field is processed according to different time intervals.
7. The method according to claim 6, characterized in that The step of determining a target dimension data item to be analyzed from the target non-time dimension field includes: Determine a target processing mode corresponding to the target metric field, and process the metric data items corresponding to each dimensional data item in the target non-time dimension field in the target metric field according to the target processing mode; sorting the dimension data items in the target non-time dimension field according to the processing result; The target dimension data item to be analyzed is determined from the target non-time dimension field according to the sorting result.
8. The method according to claim 6, characterized in that According to the processing results, a visual analysis result of the data table is generated, including: The following processing is performed for each set time interval: According to the processing result of the metric data item corresponding to the target dimensional data item in the target metric field, the target dimensional data item and multiple time periods corresponding to the time interval are used as a cross-dimensional field group to construct a corresponding data cross-tabulation; A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
9. The method according to claim 6, characterized in that According to the processing results, a visual analysis result of the data table is generated, including: When at least two target metric fields are identified from the data table, the following processing is performed for each set time interval: According to the processing result of the metric data item corresponding to the target dimensional data item in each of the target metric fields, the target dimensional data item and at least two of the target metric fields are used as a cross-dimensional field group to construct a corresponding data cross-tabulation table; A visual analysis result of the data table corresponding to the time interval is generated according to the data cross table.
10. The method according to claim 1, characterized in that: The processing of the metric data items in the target metric field according to different time intervals according to the time data items in the time dimension field is to aggregate the metric data items in the target metric field according to different time intervals; When the metric data items in the target metric field are aggregated according to different time intervals, a visual analysis result of the data table is generated according to the aggregation results of the target metric field in the different time intervals.
11. The method according to claim 10, characterized in that Generating the visual analysis result of the data table according to the aggregation result of the target metric field in the different time intervals includes: The following processing is performed for each set time interval: Determining, according to an aggregation result of the target metric field in the time interval, month-on-month change information of the target metric field corresponding to the time interval; According to the aggregation result of the target metric field in the time interval and the month-on-month change information, a visualization analysis result of the data table corresponding to the time interval is generated.
12. A data table processing device, characterized in that: The device comprises: Table acquisition module, used to obtain the data table to be processed; A field identification module, used to identify the time dimension field and the target metric field to be analyzed in the data table; an aggregation module, configured to process the metric data items in the target metric field according to different time intervals based on the time data items in the time dimension field; The visualization module is used to generate a visualization analysis result of the data table according to the processing result.
13. A storage medium, characterized in that: The storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the data table processing method described in any one of claims 1-11.