A negative sequence rule influence analysis system and method based on campus data
By designing a negative sequence rule impact analysis system based on campus data, the problem of failure to comprehensively analyze students' behavior in the existing technology is solved, and an in-depth understanding of students' learning and consumption situations is achieved, and students' overall performance is improved.
Patent Information
- Application Number
- CN202310024876.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-01-09
- Publication Date
- 2025-08-12
- Estimated Expiration
- 2043-01-09
AI Technical Summary
The existing student campus data analysis methods fail to fully consider the impact of elements or terms in the sequence, resulting in the lack of important information, and the inability to fully and accurately grasp students' learning and consumption situations. The traditional negative sequence rule mining algorithm cannot be directly used for impact-oriented negative sequence rules.
A negative sequence rules impact analysis system based on campus data is designed, including data preprocessing, frequent pattern mining, impact-oriented sequence rules mining, and contribution and impact analysis modules of missing items. The InsRule algorithm is used to mine negative sequence rules for impact-oriented and calculate the impact of missing items.
It can analyze the factors that affect students' academic performance and their influence laws more comprehensively and specifically, help school administrators reasonably guide and manage students and improve students' overall performance.
Smart Images

Figure CN116150226B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of application of negative sequence rules, and in particular to a negative sequence rule influence analysis system and method based on campus data. Background Art
[0002] In the information age, building digital campuses is becoming an increasingly important option for schools. Students' daily lives and studies generate vast amounts of data, and processing this campus data is becoming increasingly crucial for analyzing student behavior. Student campus data, recorded in the digital campus's network center, can largely reveal crucial information such as student consumption behavior and academic performance. Analyzing student campus data can help school administrators gain a comprehensive understanding of students' learning and consumption patterns, enabling them to provide appropriate guidance and management. Furthermore, school administrators can use the analysis results to implement appropriate and effective interventions to improve student performance.
[0003] Currently, the methods we have found for analyzing student campus data only analyze sequence patterns or rules as a whole to obtain information about student behavior, without specifically analyzing student behavior by focusing on elements or items within the sequence. This can lead to the loss of important information and prevent school administrators from fully and accurately understanding student learning and consumption patterns. Regarding sequential rule analysis, the only research we have found on mining impact-oriented sequential rules is Zhao et al.'s paper "Mining both positive and negative impact-oriented sequential rules from transactional data," published in the Pacific-Asia Conference on Knowledge Discovery and Data Mining, Springer, 2009, pp. 656–663. This study defines impact-oriented negative sequential rules and designs an effective algorithm, FindINSR, for mining impact-oriented sequential rules. It also employs two metrics, contribution and influence, to measure the impact of an item on the outcome. However, the study by Zhao et al. also encountered three problems: (1) The proposed algorithm for mining influence-oriented sequence rules mines positive sequence patterns from frequent sequences and negative sequence patterns from infrequent sequences. However, according to current research, this method has incomplete considerations; (2) The mining of influence-oriented negative sequence rules only considers the complete absence of the antecedent of the sequence rule, without considering the case of missing elements or missing items; (3) When analyzing the mined influence-oriented sequence rules using contribution and influence indicators, only the contribution and influence of the last item in the antecedent of the sequence rule on the occurrence of the result are analyzed, without considering other possible situations, such as the contribution and influence of items of different numbers and positions on the occurrence of the result. In addition, most of the research on sequence rules is traditional sequence rules, and there is less research on influence-oriented sequence rules. Due to the differences between influence-oriented sequence rules and traditional sequence rules, the relevant algorithms for mining traditional negative sequence rules cannot be directly used to mine influence-oriented negative sequence rules. Summary of the Invention
[0004] In order to make up for the deficiencies of the prior art, the present invention provides a negative sequence rule influence analysis system and method based on campus data.
[0005] The present invention is achieved through the following technical solutions:
[0006] A negative sequence rule influence analysis system based on campus data, characterized by: comprising a data preprocessing module for preprocessing data obtained from a school information network center, combining different required data, and storing them in a student campus sequence database in the form of a sequence;
[0007] Frequent pattern mining module, used to mine positive and negative frequent sequence patterns from the student campus sequence database, and store the positive and negative frequent sequence patterns and their corresponding support into the frequent pattern result set;
[0008] The impact-oriented sequence rule mining module is used to mine the positive and negative frequent sequence patterns obtained by the frequent pattern mining module to obtain all the impact-oriented sequence rules that meet the constraints;
[0009] The contribution and impact analysis module of missing items is used to calculate the contribution and impact of one or more missing items in the antecedent of the negative sequence rule on the occurrence of the result;
[0010] The graphical interface presentation module is used to present the analysis results in different categories on the graphical interface of the system.
[0011] A negative sequence rule influence analysis method based on campus data includes the following steps:
[0012] S100, data preprocessing, cleaning the data obtained from the school information network center, replacing the complex field formats in the original data with simple formats, and then processing the data into a sequence format and storing it in the student campus sequence database;
[0013] S200, frequent pattern mining, setting a minimum support threshold (min-sup), and using a sequential pattern mining algorithm to mine positive and negative frequent sequential patterns from the student campus sequence database, and storing the positive and negative frequent sequential patterns and their corresponding supports into a frequent pattern result set PNSP;
[0014] S300, impact-oriented sequence rule mining, the positive and negative frequent sequence patterns mined above are screened to obtain sequence patterns that meet the requirements, and all candidate sequence rules for impact are obtained through a candidate sequence rule generation method; then, the candidate sequence rules for impact are screened according to the minimum support threshold, minimum lift threshold (min-lift), and minimum confidence threshold (min-conf) set by the user, to obtain all impact-oriented sequence rules that meet the constraints;
[0015] S400, analyzing the influence of missing items in the impact-oriented negative sequence rule, calculating the contribution and influence of one or more missing items in the antecedent of the impact-oriented negative sequence rule on the occurrence of the result;
[0016] S500: Display the analysis results on a graphical interface.
[0017] In step S200 , the modified PrefixSpan algorithm is used to mine all positive frequent sequential patterns, and the NegI-NSP algorithm is used to mine all negative frequent sequential patterns.
[0018] The step S300 specifically includes S310: for each sequence pattern in the PNSP set, if its size is greater than 1 and the last element in the pattern is an influence (or result), then a candidate sequence rule generation method is used to generate a candidate sequence rule.
[0019] S320 then determines whether the antecedent and consequent of the candidate sequence rule facing the influence are both frequent. If both are frequent, the candidate sequence rule is calculated. Support
[0020] S330, determine the relationship between the support of the candidate sequence rule and the minimum support threshold set by the user. If the support of the current candidate sequence rule is greater than or equal to the minimum support threshold set by the user, calculate the candidate sequence rule. The degree of improvement
[0021] S340, determine the relationship between the lift of the candidate sequence rule and the minimum lift threshold set by the user. If the lift of the current candidate sequence rule is greater than or equal to the minimum lift threshold set by the user, calculate the candidate sequence rule. Confidence
[0022]
[0023] S350: Determine the relationship between the confidence of the candidate sequence rule and the minimum confidence threshold set by the user. If the confidence of the current candidate sequence rule is greater than or equal to the minimum confidence threshold set by the user, store this candidate sequence rule in the set SRC. Continuously update the maximum confidence value of the rules in the sequence rule set, and ultimately obtain the maximum confidence value max_conf of all candidate sequence rules.
[0024] S360, calculating the normalized confidence of each sequence rule in the SRC set.
[0025] The candidate sequence rule generation method is to filter out all sequence patterns whose last element is an influence (or result) from all positive and negative frequent sequence patterns that have been mined, use the last element as the consequent of the rule, and the remaining elements as the antecedents of the rule, to generate influence-oriented candidate sequence rules.
[0026] The candidate sequence rule The calculation formula for support is Where |D| is the number of tuples in the sequence database D, The sequence obtained by merging the antecedent X and consequent Y of the rule.
[0027] The candidate sequence rule The calculation formula for the lift is
[0028] The candidate sequence rule The confidence calculation formula is
[0029] The calculation formula of the normalized confidence is:
[0030] The contribution includes the contribution of the missing item n in any element in the sequence rule antecedent to the occurrence of the result Y Where n represents the missing item in any negative element of the rule antecedent X, and X\n represents the sequence obtained by removing item n from the negative sequence X;
[0031] And the contribution of all missing items in the sequence rule antecedent to the occurrence of the result Y Where MPS(X) is the maximum positive subsequence of the negative sequence X, and Nmps represents the set of all negative items removed from the negative sequence X;
[0032] The influence is calculated by the following formula:
[0033]
[0034] Where N represents one or more missing items in the sequence rule antecedent X.
[0035] The present invention has the following technical advantages:
[0036] The present invention provides a negative sequence rule influence analysis system based on campus data, which mines influence-oriented negative sequence rules from the student campus sequence database, and for the influence-oriented negative sequence rules with multiple negative elements, calculates the influence of the missing items in any element in the sequence rule antecedent on the result, and also calculates the influence of all missing items in the sequence rule antecedent on the result. Based on the student campus data sequence data, the influence-oriented sequence rules are mined, and the influence of the relevant missing items in the influence-oriented negative sequence rule antecedent on the result is calculated, which can more comprehensively and specifically analyze the factors affecting students' academic performance and their influence patterns. The present invention analyzes the factors affecting students' academic performance and their influence patterns through students' consumption behavior, which can help school administrators fully grasp students' learning and consumption situations, so as to provide reasonable guidance and management for students; at the same time, school administrators can also adopt appropriate and effective methods to intervene in students' behavior according to the analysis results to improve students' overall performance. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] The present invention will be further described below with reference to the accompanying drawings.
[0038] Figure 1 This is a flowchart of the InsRule algorithm in the present invention for mining influence-oriented sequence rules and calculating the influence of missing items.
[0039] Figure 2 This is a flowchart of the negative sequence rule influence analysis method based on student campus data of the present invention;
[0040] Figure 3 This is a structural block diagram of the implementation system of the negative sequence rule influence analysis method based on student campus data of the present invention. DETAILED DESCRIPTION
[0041] The positive and negative frequent sequence patterns described below are referred to as positive frequent sequence patterns and negative frequent sequence patterns.
[0042] To address the problems of the prior art, this invention proposes a system for mining impact-oriented negative sequence rules based on campus data and analyzing the impact of related missing items. It also proposes a method for calculating the impact of missing items in impact-oriented negative sequence rules. This method involves calculating the impact of missing items in any negative element within the sequence rule's antecedent and the impact of all missing items within the sequence rule's antecedent, thereby calculating the impact of these missing items on the results. By analyzing impact-oriented sequence rules, valuable information can be obtained, facilitating decision-makers' method selection and implementation. This invention uses the sequence rule impact method to analyze student campus data, analyzing the factors influencing academic performance and their patterns of influence based on student consumption behavior. This analysis system can reveal patterns in student behavior, such as the greater the likelihood of poor grades; that eating breakfast on Saturdays and Sundays has a greater impact on grades than on other days of the week; and that eating breakfast during exam weeks has a greater impact on grades than on non-exam weeks. The impact analysis results can help school administrators gain a comprehensive understanding of students' learning and consumption patterns, enabling them to provide appropriate guidance and management. Furthermore, school administrators can use the analysis results to implement appropriate and effective behavioral interventions to improve overall student performance.
[0043] In order to effectively analyze student campus data, the following key issues should be considered: (1) How to mine impact-oriented negative sequence rules based on student campus sequence data; (2) How to analyze the impact of missing items in any negative element in the sequence rule antecedent on the results based on the impact-oriented negative sequence rules; (3) How to analyze the impact of all missing items in the sequence rule antecedent on the results based on the impact-oriented negative sequence rules.
[0044] Most of the research on sequence rules focuses on traditional sequence rules, while there is less research on influence-oriented sequence rules. Due to the differences between influence-oriented sequence rules and traditional sequence rules, the related algorithms of traditional negative sequence rules cannot be directly used to mine influence-oriented negative sequence rules.
[0045] To address these issues, this paper proposes a new algorithm, InsRule, to mine impact-oriented negative sequence rules. It calculates the impact of missing terms in any negative element within the sequence rule's antecedent on the result, as well as the impact of all missing terms within the sequence rule's antecedent on the result. The main contributions of this paper are summarized as follows:
[0046] First, we modified the candidate sequence rule generation method in the existing negative sequence rule mining algorithm nspRule to generate influence-oriented candidate sequence rules, and further mined influence-oriented negative sequence rules that met the constraints.
[0047] Secondly, the influence calculation method proposed by Zhao et al. was modified. It was expanded on the basis of only calculating the influence of the last item in the antecedent of the sequence rule, including: 1) for the influence-oriented negative sequence rule with multiple negative elements, the influence of the missing items in any negative element in the antecedent of the sequence rule on the result is calculated; 2) the influence of all missing items in the antecedent of the influence-oriented negative sequence rule on the result is calculated.
[0048] Finally, a new algorithm, InsRule, is proposed to mine impact-oriented negative sequence rules and calculate the influence of missing items. By mining impact-oriented negative sequence rules based on student campus sequence data and calculating the impact of missing items in the antecedents of these impact-oriented negative sequence rules on the outcomes, we can more specifically analyze the factors affecting student academic performance and their influence patterns. This helps school administrators gain a comprehensive understanding of students' learning and consumption patterns, enabling them to provide appropriate guidance and management. Furthermore, based on the analysis results, school administrators can adopt appropriate and effective methods to intervene in student behavior to improve overall student performance.
[0049] The technical solution of the present invention is described in detail below.
[0050] The present invention provides a negative sequence rule influence analysis system based on campus data, including a data preprocessing module for preprocessing data obtained from the school information network center, deleting duplicate, erroneous and incomplete data, combining the required different data after desensitization, and storing them in the form of sequences in a student campus sequence database.
[0051] The frequent pattern mining module is used to mine positive and negative frequent sequence patterns from the student campus sequence database, and store the positive and negative frequent sequence patterns (pnsp) and their corresponding support into the frequent pattern result set PNSP.
[0052] The impact-oriented sequence rule mining module is used to screen the positive and negative frequent sequence patterns obtained by the frequent pattern mining module to obtain sequence patterns that meet the requirements; then, a candidate sequence rule generation method is used to obtain all impact-oriented candidate sequence rules; then, the support, lift, and confidence of the rules are calculated, and the candidate sequence rules are screened according to the set minimum support threshold, minimum lift threshold, and minimum confidence threshold to obtain all impact-oriented sequence rules that meet the constraints.
[0053] The contribution and influence analysis module of missing items is used to calculate the contribution and influence of one or more missing items in the antecedent of the negative sequence rule oriented towards impact on the occurrence of the result.
[0054] The graphical interface representation module is used to represent the above-mentioned impact-oriented negative sequence rules and related impact analysis results in different categories on the graphical interface of the system.
[0055] The present invention also provides a negative sequence rule influence analysis method for campus data based on the above system, which specifically includes the following steps.
[0056] S100, perform data preprocessing. The data preprocessing module first cleans the student campus data. Since the data obtained from the school information network center is in the format of text documents, problems such as missing data, data noise, and data inconsistency are inevitable. In the process of processing text format data, duplicate data, erroneous data, and incomplete data need to be deleted. Then, the student consumption data and student academic performance data are combined, and the student ID number is desensitized. In order to obtain a suitable sequence data set for mining and analysis, it is first necessary to replace the complex field format in the original data with a simple format. For example, the student's grades are changed to two levels, with grades greater than or equal to 80 being "good" and otherwise "poor". In addition, the time period is divided into a week as a cycle, that is, the student's consumption data in each week is a sequence; then it is divided into daily time periods, that is, the daily consumption record is an element in the sequence, and the items in the element are the daily meals. The obtained sequence is stored in the student campus sequence database.
[0057] For example, the consumption data and academic performance data of some students in a certain university in one semester are shown in Tables 1 and 2.
[0058] The student consumption data is shown in Table 1. Each column of the table represents the number of rows, student ID (anonymized), consumption location, consumption amount and transaction time.
[0059] Table 1 Consumption data of college students' one-card system
[0060]
[0061]
[0062] Some data on students’ academic performance are shown in Table 2, where each column represents the number of rows, student ID (after desensitization), semester, grade, and subject type.
[0063] Table 2 Student academic performance data
[0064] Number of lines Student ID semester score Subject Type 1 201A51009 2016-2017 79 Compulsory Courses 2 201A01014 2016-2017 51 ElectiveCourses 3 201A01019 2016-2017 60 Compulsory Courses 4 201B51248 2016-2017 90 Compulsory Courses 5 201A21051 2016-2017 97 ElectiveCourses 6 201B91027 2016-2017 81 Compulsory Courses 7 201A21113 2016-2017 67 Compulsory Courses 8 201A91012 2016-2017 80 ElectiveCourses
[0065] We then combined the two types of tables to analyze the relationship between student consumption behavior and academic performance. We used the student ID number as the primary key to link the two tables, and selected some useful attributes from the newly synthesized table. Table 3 shows a portion of the resulting data.
[0066] Table 3 Combined table of student consumption data and academic performance data
[0067] Student ID number date Trading Hours score 201B41013 20160903 2016-09-0309:13:00 68 201B51012 20160903 2016-09-0309:13:00 72 201A51068 20160903 2016-09-0309:14:00 82 201A51074 20160903 2016-09-0309:14:00 90 201A51058 201601117 2016-11-1717:20:00 65 201A51066 201601117 2016-11-1717:20:00 73 201B41013 201601117 2016-11-1717:21:00 68 201A51058 201601117 2016-11-1717:44:00 65
[0068] Next, the data is further processed into a sequence format. To obtain a suitable sequence dataset for mining and analysis, the complex fields in the original data must first be replaced with a simpler format. For example, in Table 3, the "Transaction Time" field is too long and needs to be processed. Based on the "Transaction Time" field, two new fields are added: "Number of Meals" and "Number of Weeks." The specific time is converted into whether the student consumed food in the cafeteria during the three meal time periods. If there is a consumption record within the three meal time periods, the student is considered to have a regular meal schedule. Meal times are defined as: 7:00-8:30 (breakfast), 11:30-1:30 (lunch), and 17:00-19:00 (dinner). The day of the week is calculated based on the consumption date and represented in a new format as the "Number of Meals" field. For example, the time "2016-08-28 08:30:00" is represented as "Sun-breakfast." The prefix represents the day of the week, consisting of Mon, Tue, Wed, Thu, Fir, Sat, and Sun, representing Monday through Sunday, respectively. The suffix represents the three meals, consisting of breakfast, lunch, and dinner, respectively. The week of the year is calculated based on the consumption date and used as the new "Week Number" field. For example, the date "2016-08-28" belongs to the 35th week of 2016.
[0069] After creating a join table, we can see the academic performance corresponding to the student's consumption data. To further process the performance data, we set the student's performance to a two-tiered level: "Good" for scores greater than or equal to 80, and "Poor" for scores otherwise. For example, if student 201B51010's performance is 88, the performance is changed to "Good." The data obtained after transforming the aforementioned fields is shown in Table 4.
[0070] Table 4 Partial data after conversion
[0071] Student ID Trading Hours Number of meals Week Grade 201B41013 2016-08-2212:43:00 Monday-lunch 35 poor 201B41013 2016-08-2307:49:00 Tue-breakfast 35 poor 201B41013 2016-08-2312:23:00 Tue-lunch 35 poor 201B41013 2016-08-2412:15:00 Wed-lunch 35 poor 201B41013 2016-08-2417:47:00 Wednesday dinner 35 poor 201B41013 2016-08-2912:53:00 Monday-lunch 36 poor 201B41013 2016-08-2918:01:00 Mon-dinner 36 poor 201A51068 2016-08-2207:38:00 Monday-breakfast 35 good 201A51068 2016-08-2307:39:00 Tue-breakfast 35 good 201A51068 2016-09-1211:36:00 Monday-lunch 38 good
[0072] The data is divided into time periods based on a weekly cycle, representing a sequence of students' weekly consumption data. The data is further divided into time periods based on a daily cycle, representing each day's consumption record as an element in the sequence, where each element represents the daily meal schedule. If a student with a score of 80 or above eats three meals regularly from Monday to Friday, the sequence is: <(Mon-breakfast, Mon-lunch, Mon-dinner), (Tue-breakfast, Tue-lunch, Tue-dinner), (Wed-breakfast, Wed-lunch, Wed-dinner), (Thu-breakfast, Thu-lunch, Thu-dinner), (Fir-breakfast, Fir-lunch, Fir-dinner), good>.
[0073] S200, frequent pattern mining. Set a minimum support threshold and use a sequential pattern mining algorithm to mine positive and negative frequent sequential patterns from the student campus sequence database. Based on the student campus sequence database obtained in S100 and the user-set minimum support threshold, use the modified PrefixSpan algorithm to mine all positive frequent sequential patterns, and use the NegI-NSP algorithm to mine all negative frequent sequential patterns. The positive and negative frequent sequential patterns (pnsp) and their corresponding supports are stored in the frequent pattern result set PNSP.
[0074] The modified PrefixSpan algorithm comes from "Toward to better structure and constraint to mine negative sequential patterns" published by X.Gao, Y.Gong, T.Xu, J.Lü, Y.Zhao, and X.Dong et al. in IEEE Transactions on Neural Networks and Learning Systems in 2020.
[0075] The NegI-NSP algorithm comes from "Negi-nsp: Negative sequential pattern mining based on loose constraints" by P.Qiu, L.Zhao, and X.Dong et al., published in IECON 2017-43rdAnnual Conference of the IEEE Industrial Electronics Society. IEEE, 2017, pp.3419–3425.
[0076] S300, impact-oriented sequence rule mining, filters the mined positive and negative frequent sequence patterns to obtain qualified sequence patterns. A candidate sequence rule generation method is then used to obtain all candidate sequence rules for impact. These candidate sequence rules are then further filtered to obtain all constraint-satisfied impact-oriented sequence rules. For the positive and negative frequent sequence patterns mined in S200, a candidate sequence rule generation method is first applied to obtain all candidate sequence rules for impact. The support, lift, and confidence of the candidate sequence rules are then calculated. The candidate sequence rules are then filtered based on user-defined minimum support, lift, and confidence thresholds to obtain all constraint-satisfied impact-oriented sequence rules.
[0077] Specifically, S310 generates an impact-oriented candidate sequence rule according to a candidate sequence rule generation method. For each sequence pattern in the PNSP set, if its size is greater than 1 and the last element in the pattern is an impact (or result), the candidate sequence rule generation method is used to generate a candidate sequence rule. Specifically, all the sequence patterns whose last element is influence (or result) are screened from all the positive and negative frequent sequence patterns that have been mined. The last element, that is, the influence, is used as the consequent of the rule, and the remaining elements are used as the antecedents of the rule to generate candidate sequence rules oriented to influence. Specifically, if the sequence s= <e1e2e3…e k T>, T is the influence (or result), the candidate sequence rule is generated by dividing s into two parts, that is, the antecedent of the rule is X= <e1e2e3…e k >, the consequent of the rule is Y= <t>.
[0078] S320 determines whether the antecedent and consequent of the candidate sequence rule facing influence are both frequent. If both are frequent, then the formula Computing candidate sequence rules Support Whether they are frequent is determined by whether the support of the antecedent and consequent of the candidate sequence rule meets the minimum support threshold constraint. The support of the sequence rule is, for a given sequence database D and a given sequence rule The number of tuples in the sequence database D is represented by |D|, where a tuple is represented by<sid(sequence-ID),ds(data sequence)> D contains The number of tuples is expressed as The support in D is expressed as By formula |Calculated. Represents the sequence obtained by combining the antecedent X and the consequent Y of the rule, for example, X=<a,b> , Y= <c>,but The sequence database D here is a general term used to explain how the support of sequence rules is calculated. In the present invention, it is the student campus sequence database that was initially established.
[0079] S330, determine the relationship between the support of the candidate sequence rule and the minimum support threshold set by the user. If the support of the current candidate sequence rule is greater than or equal to the minimum support threshold set by the user, then use the formula The improvement of the candidate sequence rule is further calculated. The improvement of the sequence rule is the improvement of the given sequence database D and the given sequence rule. Sequence rules The improvement is expressed as sup(X) and sup(Y) represent the support of X and Y respectively.
[0080] S340, determine the relationship between the lift of the candidate sequence rule and the minimum lift threshold set by the user. If the lift of the current candidate sequence rule is greater than or equal to the minimum lift threshold set by the user, then use the formula The confidence of the candidate sequence rule is further calculated.
[0081] S350, determine the relationship between the confidence of the candidate sequence rule and the minimum confidence threshold set by the user. If the confidence of the current candidate sequence rule is greater than or equal to the minimum confidence threshold set by the user, then store this candidate sequence rule in the set SRC. The confidence of the sequence rule is, which means the sequence rule The strength of the association between the antecedent X and the consequent Y of a rule is called the confidence of the rule, which is expressed as In the traditional support-confidence framework, rule confidence values are in the interval [0, 1], and users can set different confidence levels based on their needs. However, because negative sequence patterns do not satisfy the downward closure property, the support of a superset s' of an itemset s may be greater than the support of itemset s, resulting in a rule confidence greater than 1. This no longer conforms to the conventional support-confidence framework and makes it difficult to set an appropriate minimum confidence threshold.
[0082] The value of the maximum confidence max_conf of the rules in the sequence rule set is continuously updated, and finally the maximum confidence value of all candidate sequence rules is obtained.
[0083] S360, calculate the normalized confidence of each sequence rule in the SRC set. Calculate the normalized confidence of the sequence rules and delete the sequence rules that do not meet the minimum confidence threshold set by the user. The normalized confidence of the sequence rules is expressed as Its value falls in the interval [0,1].
[0084] S400: Impact Analysis of Missing Items in Impact-Oriented Negative Sequence Rules. Calculate the contribution and impact of one or more missing items in the antecedent of the impact-oriented negative sequence rule on the outcome. For sequence rules with normalized confidence greater than or equal to the user-defined minimum confidence threshold and missing items in the antecedent, calculate the impact of the missing items and store the corresponding impact in set Q.
[0085] The contribution is the negative sequence rule for the directional influence of multiple negative elements. The contribution of the missing item n in any element of the sequence rule antecedent to the result Y is
[0086]
[0087] Where n represents the missing item in any negative element in the sequence rule antecedent X, and X\n represents the sequence obtained by removing item n from the negative sequence X.
[0088] Calculate the contribution of all missing items in the sequence rule antecedent to the occurrence of the result Y. Assuming that the maximum positive subsequence of the negative sequence X is MPS(X), the contribution of all missing items in the sequence rule antecedent to the occurrence of the result Y is
[0089]
[0090] Where MPS(X) is the maximum positive subsequence of the negative sequence X, and Nmps represents the set of all negative items removed from the negative sequence X.
[0091] The influence degree is further calculated based on the above contribution degree to obtain the corresponding influence degree
[0092]
[0093] Where N represents one or more missing items in the sequence rule antecedent X.
[0094] Contribution shows how much the missing term N in the sequence rule contributes to the occurrence of the outcome Y, and impact measures how much it can change the outcome. They both fall in [0,∞).
[0095] S500: Display the analysis results on a graphical interface. The above-mentioned impact-oriented negative sequence rule and the impact analysis results of the related missing items are displayed on the system's graphical interface in different categories. For example, the user is provided with the items with an impact greater than a fixed value, or the proportion of items with an impact greater than a fixed value within a certain time period in all impact calculation results. The fixed value and the corresponding time period are both input by the user on the system interactive interface according to their needs.
[0096] The frequent pattern mining, influence-oriented sequence rule mining and influence degree analysis modules for missing items in influence-oriented negative sequence rules described in the above steps S200, S300 and S400 mine and analyze student campus data through the InsRule algorithm.
[0097] The InsRule algorithm is based on the negative sequential rule mining idea of the nspRule algorithm proposed by C.Sun, X.Jiang, X.Dong, T.Xu, L.Zhao, Z.Li, and Y.Zhao in the article "Mining negative sequential rules from negative sequential patterns" published in the International Conference on Database Systems for Advanced Applications. Springer, 2022, pp.459–475. It is modified on this basis to mine impact-oriented negative sequential rules. It further calculates the impact of missing items in any negative elements in the sequence rule antecedent on the result, and also calculates the impact of all missing items in the sequence rule antecedent on the result. The InsRule algorithm includes the following steps:
[0098] Step A, for positive and negative frequent sequential pattern mining, we use the modified PrefixSpan algorithm to mine all positive frequent sequential patterns and the NegI-NSP algorithm to mine all negative frequent sequential patterns.
[0099] Step B, for the generation of candidate sequence rules for influence, we first filter out all the sequence patterns whose last element is influence (or result) from all the positive and negative frequent sequence patterns mined in step A, and take the last element, that is, the influence, as the consequent of the rule, and the remaining elements as the antecedents of the rule to generate candidate sequence rules for influence. Specifically, if the sequence s= <e1e2e3…e k T>, T is the influence (or result), the candidate sequence rule is generated by dividing s into two parts, that is, the antecedent of the rule is X= <e1e2e3…e k >, the consequent of the rule is Y= <t>.
[0100] Step C: Calculation of support, lift, and confidence of the candidate sequence rules facing influence.
[0101] Step D: Calculate the contribution and influence of the missing items in the impact-oriented negative sequence rule.
[0102] This method also involves or may involve the following rules and definitions.
[0103] Generalized Negative Sequence Rule (GNSR), the generalized negative sequence rule is , where one or both of X and Y are negative sequence patterns.
[0104] Event-oriented negative sequence rule (ENSR),The event-oriented negative sequence rule is a special negative sequence rule,,where the right-hand side Y is a single event, that is, the length of Y is 1.
[0105] Impact-oriented negative sequence rule (INSR),The impact-oriented negative sequence rule is a special event-oriented negative sequence rule,,where the right-hand side is a predefined target outcome, such as a specific,category or a predetermined event.
[0106] Negative sequence rule, given a sequence rule If the rule contains at least one negative element in its antecedent or consequent, and Sequence rule It is a negative sequence rule.
[0107] The length of a sequence, denoted as length(s), is the total number of items contained in all elements of the sequence. If length(s) = k, then s is a sequence of length k.
[0108] The size of a sequence, denoted as size(s), is the total number of elements in the sequence. If size(s) = k, then s is a sequence of size k.
[0109] Supersequences and subsequences of sequences, assuming there are two sequences s α =<α1α2…α i > and s β =<β1β2…β k >, if there exists 1≤j1 <j2<…<j i ≤k such that We call the sequence s α =<α1α2…α i > is the sequence s β =<β1β2…β k > a sub-sequence, represented by sequence s β called sequence s α For example, sequence s1 =<ab(cd)> is a supersequence of sequence s2=<(cd)> (sequence s2=<(cd)> is a supersequence of sequence s1=<ab(cd)> a subsequence of ).
[0110] Negative size, the total number of negative elements in a negative sequence ns is called the negative size of ns. If negsize(ns) = n, then ns is an n-neg-size sequence. For example, given The number of negative elements is 2, so ns is a 2-neg-size sequence.
[0111] Maximum positron sequence, assuming ns= <s1s2,…,s m > is a negative sequence of m-size and n-neg-size (m>n), and the subsequence s contains all positive elements. Then s is called the maximum positive subsequence of ns, denoted as MPS(ns). For example, given We can get MPS (ns) = <ac>.
[0112] The pseudo code for calculating the influence is shown in Algorithm 1.
[0113] Algorithm 1: Impact calculation
[0114] Input: The set of negative sequence rules G for influence and the corresponding lift of the rules
[0115] Output: The influence of the missing items in the sequence rule
[0116]
[0117] The pseudo code of the InsRule algorithm is shown in Algorithm 2.
[0118] Algorithm 2: InsRule algorithm Input: student behavior sequence database D, minimum support threshold min-sup, minimum lift threshold min-lift, minimum confidence threshold min-conf
[0119] Output: Negative sequence rules for impact, the impact of missing items in the rules
[0120]
[0121]
[0122] The InsRule algorithm first mines all positive frequent sequential patterns using the modified PrefixSpan algorithm (line 1). Then, it mines all negative frequent sequential patterns using the NegI-NSP algorithm (line 2), and stores the positive and negative frequent sequential patterns (pnsp) and their corresponding supports into the set PNSP (line 3). For each sequential pattern pnsp in the PNSP set, if size(pnsp)>1 and the last element in the pattern is an influence (or result), then the candidate sequential rule generation method in step B is used to generate a candidate sequential rule. (Lines 6-8). Determine whether the antecedent and consequent of the sequence rule are both frequent. If they are both frequent, then use the formula Computing candidate sequence rules Support (Lines 9-10); If the support of the current candidate sequence rule is greater than or equal to the minimum support threshold set by the user, then the formula Further calculate the improvement of the candidate sequence rule (Lines 11-12). If the lift of the current candidate sequence rule is greater than or equal to the minimum lift threshold set by the user, then the formula Further calculate the confidence of the candidate sequence rule (Lines 13-15). The value of max_conf is continuously updated, and the maximum confidence value of all candidate sequence rules is finally obtained (Lines 16-18). If the confidence of the current candidate sequence rule is greater than or equal to the minimum confidence threshold set by the user, then this candidate sequence rule is stored in the set SRC (Lines 19-21); through the formula Calculate the normalized confidence of each sequence rule in the SRC set. If the normalized confidence of the rule is greater than or equal to the minimum confidence threshold set by the user and there are missing items in the sequence rule antecedents, calculate the impact of the missing items using Algorithm 1 and store the corresponding impact in the set Q (lines 26-32). Otherwise, if the normalized confidence of the rule is less than the minimum confidence threshold set by the user, delete the sequence rule from the set SRC (lines 33-36). Finally, return the impact-oriented sequence rule set SRC and the set Q of the impact of the missing items (line 37).< / ac> < / t> < / c> < / t>
Claims
1. A negative sequence rule influence analysis method based on campus data, characterized by: The following steps are involved: S100, data preprocessing, cleaning the data obtained from the school information network center, replacing the complex field formats in the original data with simple formats, and then processing the data into a sequence format and storing it in the student campus sequence database; S200, frequent pattern mining, setting a minimum support threshold, and using a sequence pattern mining algorithm to mine positive and negative frequent sequence patterns from the student campus sequence database, and storing the positive and negative frequent sequence patterns and their corresponding support into the frequent pattern result set PNSP; S300, mining of sequence rules oriented to influence, screening the positive and negative frequent sequence patterns mined above to obtain sequence patterns that meet the requirements, and obtaining all candidate sequence rules oriented to influence through the candidate sequence rule generation method; then, the candidate sequence rules oriented to influence are generated according to the minimum support threshold, minimum lift threshold and minimum confidence threshold set by the user. Then, we filter and obtain all the impact-oriented sequence rules that meet the constraints; This step specifically includes S310 , for each sequence pattern in the PNSP set, if its size is greater than 1 and the last element in the pattern is an influence or a result, generating a candidate sequence rule csr(X⇒Y) using a candidate sequence rule generation method; S320 then determines whether the antecedent and consequent of the influence-oriented candidate sequence rule are both frequent. If both are frequent, the support sup(X⇒Y) of the candidate sequence rule X⇒Y is calculated. S330, determining the relationship between the support of the candidate sequence rule and the minimum support threshold set by the user. If the support of the current candidate sequence rule is greater than or equal to the minimum support threshold set by the user, then calculating the lift (X⇒Y) of the candidate sequence rule X⇒Y. S340, determining the relationship between the lift of the candidate sequence rule and the minimum lift threshold set by the user. If the lift of the current candidate sequence rule is greater than or equal to the minimum lift threshold set by the user, then calculating the confidence conf(X⇒Y) of the candidate sequence rule X⇒Y. S350, determining the relationship between the confidence of the candidate sequence rule and the minimum confidence threshold set by the user. If the confidence of the current candidate sequence rule is greater than or equal to the minimum confidence threshold set by the user, then storing this candidate sequence rule in the set SRC; And the maximum confidence value of the rules in the sequence rule set is continuously updated, and finally the maximum confidence value max_conf of all candidate sequence rules is obtained; S360, calculating the normalized confidence of each sequence rule in the SRC set; S400, analyzing the influence of missing items in the impact-oriented negative sequence rule, calculating the contribution and influence of one or more missing items in the antecedent of the impact-oriented negative sequence rule on the occurrence of the result; S500: Display the analysis results on a graphical interface.
2. The negative sequence rule influence analysis method based on campus data according to claim 1 is characterized by: In step S200 , the modified PrefixSpan algorithm is used to mine all positive frequent sequential patterns, and the NegI-NSP algorithm is used to mine all negative frequent sequential patterns.
3. The negative sequence rule influence analysis method based on campus data according to claim 1 is characterized by: In step S300, the candidate sequence rule generation method is to filter out all sequence patterns whose last element is an influence from all positive and negative frequent sequence patterns that have been mined, use the last element as the consequent of the rule, and the remaining elements as the antecedents of the rule, to generate influence-oriented candidate sequence rules.
4. The negative sequence rule influence analysis method based on campus data according to claim 1 is characterized by: In step S200, the support of the candidate sequence rule X⇒Y is calculated as sup(X⇒Y)=sup(X⋈Y) / |D|, where |D| is the number of tuples in the sequence database D, and X⋈Y is the sequence obtained by merging the antecedent X and the consequent Y of the rule.
5. The method for analyzing the influence of negative sequence rules based on campus data according to claim 4 is characterized in that: The calculation formula for the lift of the candidate sequence rule X ⇒ Y is lift(X ⇒Y)=(sup(X ⋈Y)*|D|) / (sup(X)*sup(Y)).
6. The negative sequence rule influence analysis method based on campus data according to claim 5 is characterized by: The confidence calculation formula of the candidate sequence rule X⇒Y is conf(X⇒Y)=sup(X⇒Y) / sup(X).
7. The negative sequence rule influence analysis method based on campus data according to claim 6 is characterized by: The calculation formula of the normalized confidence is nor_conf(X⇒Y)=conf(X⇒Y) / max_conf.
8. The negative sequence rule influence analysis method based on campus data according to claim 7 is characterized by: The contribution degree includes the contribution of the missing term n in any element of the sequence rule antecedent to the occurrence of the result Y: contribution(n,X)=lift(X⇒Y) / lift(X\n⇒Y), where n represents the missing term in any negative element of the rule antecedent X, and X\n represents the sequence obtained by removing the term n from the negative sequence X. And the contribution of all missing items in the sequence rule antecedent to the occurrence of the result Y is contribution(Nmps,X)=lift(X⇒Y) / lift(MPS(X)⇒Y), where MPS(X) is the largest positive subsequence of the negative sequence X, and Nmps represents the set of all negative items removed from the negative sequence X; The influence is calculated by the following formula: impact(N,X)= , Where N represents one or more missing items in the sequence rule antecedent X.
9. A system using the negative sequence rule influence analysis method according to claim 1, characterized in that: It includes a data preprocessing module, which is used to preprocess the data obtained from the school information network center, combine the required different data, and store them in the form of sequences in the student campus sequence database; Frequent pattern mining module, used to mine positive and negative frequent sequence patterns from the student campus sequence database, and store the positive and negative frequent sequence patterns and their corresponding support into the frequent pattern result set; The impact-oriented sequence rule mining module is used to mine the positive and negative frequent sequence patterns obtained by the frequent pattern mining module to obtain all the impact-oriented sequence rules that meet the constraints; The contribution and impact analysis module of missing items is used to calculate the contribution and impact of one or more missing items in the antecedent of the negative sequence rule on the occurrence of the result; The graphical interface presentation module is used to present the analysis results in different categories on the graphical interface of the system.
Citation Information
Patent Citations
Purchase behavior analysis method for mining decidable negative sequence pattern in infrequent sequence
CN107515942A
A method of mining positive and negative sequence rules
CN109146542A