A visual analysis system and method for traditional Chinese medicine case data
The visualization analysis system for TCM case data, employing a multi-dimensional analysis model and visualization output module, solves the problem of multi-dimensional automated processing of TCM case data analysis tools, achieving efficient and convenient data cleaning, analysis, and visualization, and improving the convenience and accuracy of TCM drug research.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- SUZHOU TRADITIONAL CHINESE MEDICINE HOSPITAL
- Filing Date
- 2026-03-19
- Publication Date
- 2026-06-19
AI Technical Summary
Existing TCM case data analysis tools cannot achieve multi-dimensional automated analysis, are cumbersome to operate, have inconsistent data processing, fragmented analysis processes, lack ease of use, cannot deeply explore medication patterns, have poor versatility, and lack AI-assisted analysis capabilities.
This invention provides a visualization analysis system for TCM case data, including a data analysis module and a visualization output module. It adopts a multi-dimensional analysis model for automated processing, integrates conventional and original analysis models, supports data cleaning, multi-dimensional analysis and visualization output, and realizes one-click processing of the entire process.
It achieves fully automated processing, improves processing efficiency and accuracy, lowers the operating threshold, supports multiple data formats, adapts to different diseases, can deeply explore medication patterns, and generate multi-dimensional visual analysis results.
Smart Images

Figure CN122245815A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of traditional Chinese medicine medical data processing technology, and in particular relates to a visualization analysis system and visualization analysis method for traditional Chinese medicine case data. Background Technology
[0002] With the advancement of TCM medical informatization, the accumulation of TCM case data, prescriptions, and other data is growing rapidly. TCM medication data analysis and visualization technology is gradually becoming an important support for TCM clinical research, inheritance, and innovation. Currently, related technologies have been applied in the fields of TCM medical treatment and scientific research.
[0003] In existing technologies, processed TCM medication data can be displayed in chart form using medical data visualization tools, such as drug frequency bar charts and compatibility network diagrams. However, these methods can only achieve single-dimensional or fixed-dimensional display. Multi-dimensional analysis requires manual parameter switching and model adjustment, and cannot be seamlessly integrated with data processing and pattern mining processes.
[0004] Therefore, there is an urgent need to provide a visualization analysis system and method for TCM case data. Summary of the Invention
[0005] In view of the shortcomings of the prior art, the purpose of this application is to provide a visualization analysis system and visualization analysis method for traditional Chinese medicine case data.
[0006] The first aspect of this application proposes a visualization and analysis system for traditional Chinese medicine case data, including: The data analysis module is used to analyze medication patterns by calling a preset multi-dimensional analysis model based on the standardized data corresponding to the raw data input by the user, and to generate a multi-dimensional analysis dataset. The multi-dimensional analysis model includes a conventional analysis model and an original analysis model. The original analysis model is a medication change analysis model for multiple treatments of the same disease. It is used to analyze the medication adjustment patterns and symptom changes of patients with the same disease who have visited the hospital multiple times, according to the order of their visits. The visualization output module is used to generate and output visualization charts or visualization reports based on the multi-dimensional analysis dataset and preset visualization templates.
[0007] Preferably, the visualization analysis system further includes: The data import module is used to receive raw data imported by the user, which includes multiple patients' TCM medical records and / or prescriptions; The cleaning and processing module is used to standardize the raw data, obtain standardized data, and send it to the data analysis module.
[0008] Preferably, the process by which the cleaning module standardizes the raw data includes: Based on a pre-defined cleaning rule base and in accordance with a standard terminology dictionary, descriptions in the original data that are inconsistent with the disease and medication names in the standard terminology dictionary are screened, identified, and replaced. The original case data, after being screened, identified, and replaced, is split and populated to output standardized structured data.
[0009] Preferably, the conventional analysis model is configured to perform at least one of the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis, and generate corresponding analysis data.
[0010] Preferably, the original analysis model is configured as follows: Patients with the same single disease and multiple medical records were selected as target patients, and their complete medical and medication data were screened. Using the order of visit time as the axis, extract the medication change information of each patient from the second, third, up to the Nth visit compared to the previous visit. The medication change information includes the changes of each drug, such as increase, decrease, or no change. Statistical analysis was performed on the changes in medication use of all target patients under different number of visits, calculating the percentage increase, decrease, and no change for each drug under the corresponding number of visits, and the number of case groups involved was counted. After sorting by the number of cases in descending order, the drugs with the highest percentages were selected, and a medication change dataset was generated with the number of visits as the dimension, drug name as the category, and percentage change as the numerical value. Based on the aforementioned medication change dataset, the percentage of increases, decreases, and unchanged rates for the top M drugs under a specified number of visits is visualized.
[0011] Preferably, the visualization output module includes: An operation acquisition unit is used to acquire user interaction operations, including switching the number of visits, adjusting the number of displayed drugs, clicking on data items to view corresponding case information, and filtering data by disease for the multi-dimensional analysis dataset. The information output unit is used to obtain the corresponding visualization template based on the interactive operation and use it as the target template, and to generate and output the visualization chart or visualization report based on the target template and the data selected by the interactive operation.
[0012] The second aspect of this application proposes a method for visual analysis of traditional Chinese medicine case data, including: Based on the standardized data corresponding to the raw data input by the user, a preset multi-dimensional analysis model is invoked to analyze medication patterns and generate a multi-dimensional analysis dataset; based on the multi-dimensional analysis dataset and a preset visualization template, a visualization chart or visualization report is generated and output. The multi-dimensional analysis model includes a conventional analysis model and an original analysis model. The original analysis model is a medication change analysis model for multiple treatments of the same disease. It is used to analyze the medication adjustment patterns and symptom changes of patients with the same disease who have visited multiple times, according to the order of their visits.
[0013] Preferably, the conventional analysis model is configured to perform at least one of the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis, and generate corresponding analysis data.
[0014] Preferably, the original analysis model is configured as follows: Patients with the same single disease and multiple medical records were selected as target patients, and their complete medical and medication data were screened. Using the order of visit time as the axis, extract the medication change information of each patient from the second, third, up to the Nth visit compared to the previous visit. The medication change information includes the changes of each drug, such as increase, decrease, or no change. Statistical analysis was performed on the changes in medication use of all target patients under different number of visits, calculating the percentage increase, decrease, and no change for each drug under the corresponding number of visits, and the number of case groups involved was counted. After sorting by the number of cases in descending order, the drugs with the highest percentages were selected, and a medication change dataset was generated with the number of visits as the dimension, drug name as the category, and percentage change as the numerical value. Based on the aforementioned medication change dataset, the percentage of increases, decreases, and unchanged rates for the top M drugs under a specified number of visits is visualized.
[0015] Preferably, the step of generating and outputting visual charts or visual reports based on the multi-dimensional analysis dataset and a preset visualization template includes: The user's interactive operations are obtained, including switching the number of visits, adjusting the number of displayed drugs, clicking on data items to view corresponding case information, and filtering data by disease for the multi-dimensional analysis dataset. The corresponding visualization template is obtained based on the interactive operation and used as the target template. Based on the target template and the data selected by the interactive operation, a visualization chart or visualization report is generated and output.
[0016] The technical solution provided in this application enables one-click automated processing throughout the entire process, eliminating the need for manual intervention in data cleaning, parameter configuration, and model switching, thus significantly improving processing efficiency and accuracy. It integrates conventional and original analytical dimensions to uncover deep-seated medication patterns. The operation threshold is low, requiring no professional technicians; users only need to import data to automatically obtain analysis results and visualization reports. It supports the import of data in multiple formats, adapting to different diseases and data sources, and is highly versatile with a wide range of application scenarios. Attached Figure Description
[0017] The accompanying drawings are for illustrative purposes only and are not intended to limit the scope of this application. Throughout the drawings, the same reference numerals denote the same components. Obviously, the drawings described below are merely some embodiments described in this application, and those skilled in the art can obtain other drawings based on these drawings.
[0018] Figure 1 This is a framework diagram of a visualization analysis system for traditional Chinese medicine case data provided in an embodiment of this application.
[0019] Figure 2 This is a flowchart illustrating a method for visualizing and analyzing TCM case data provided in an embodiment of this application.
[0020] Figure 3 This is a flowchart illustrating another method for visualizing and analyzing TCM case data provided in this application embodiment.
[0021] Figure 4 This is a schematic diagram of the process for standardizing raw data provided in the embodiments of this application.
[0022] Figure 5 This is a schematic diagram of the process for generating and outputting visual charts or visual reports provided in the embodiments of this application.
[0023] Figure 6 This is a schematic diagram of the data presentation for drug frequency analysis provided in the embodiments of this application.
[0024] Figure 7 This is a schematic diagram showing the data presentation of the medicinal properties and flavor ratio analysis provided in the embodiments of this application.
[0025] Figure 8 This is a schematic diagram showing the data presentation of the meridian tropism ratio analysis provided in the embodiments of this application.
[0026] Figure 9 This is a schematic diagram of the data presentation of drug relationship network analysis provided in the embodiments of this application.
[0027] Figure 10 This is a schematic diagram of the data presentation of drug clustering analysis provided in the embodiments of this application.
[0028] Figure 11 This is a schematic diagram of the data presentation of drug-related thermodynamic analysis provided in the embodiments of this application.
[0029] Figure 12 This is a graph showing the changes in medication usage and the number of medical visits provided in the embodiments of this application.
[0030] Figure 13 This is a schematic diagram illustrating the reading of the case information list provided in an embodiment of this application.
[0031] Figure 14 This is a schematic diagram showing the detailed medication information and comparison provided in the embodiments of this application. Detailed Implementation
[0032] To enable those skilled in the art to better understand the technical solutions in the embodiments of this application, the technical solutions of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. It should be understood that these descriptions are exemplary only and are not intended to limit the scope of this application. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this application. Furthermore, in the following description, descriptions of well-known structures and technologies are omitted to avoid unnecessarily obscuring the concepts disclosed in this application.
[0033] Among related technologies, those for processing TCM case / prescription data, analyzing medication patterns, and visualization, while capable of achieving some basic functions, have many significant shortcomings. They cannot meet the needs for efficient, convenient, comprehensive, and accurate processing and analysis in TCM clinical research, inheritance and innovation, and practical applications. Specifically: 1. Cumbersome and inconsistent data processing: Most existing tools require the import of pre-standardized, structured case / prescription data, and different types of analysis require different data structures in different formats, making the operation very demanding. However, in actual clinical scenarios, prescriptions often have inconsistent drug names and non-standard descriptions, and clinicians are mainly focused on diagnosis and treatment, generally lacking the ability to process structured data, making it difficult to meet the data import requirements of existing tools. In addition, existing technologies lack core functions such as automatic data cleaning, deduplication, and terminology normalization (e.g., classifying the same drug with different names in a unified manner), requiring a significant amount of time and effort to complete data preprocessing. This is not only extremely inefficient but also prone to data bias due to human error, which in turn affects the accuracy and reliability of subsequent medication pattern analysis results.
[0034] 2. Fragmented analysis process with no integrated capability: In existing technologies, data import, preprocessing, medication pattern analysis, and visualization are independent processes that require separate operations. Some processes even require switching between multiple different tools (e.g., using one software to process data, another for analysis, and a third for visualization). The lack of an integrated processing platform leads to cumbersome operation steps, high learning costs, and the inability to seamlessly connect data from different stages, resulting in data loss, format incompatibility, and other problems that seriously affect overall processing efficiency.
[0035] 3. Limited analytical dimensions, making it difficult to uncover deep-seated medication patterns: Existing tools employ relatively simple analytical methods, mostly limited to conventional dimensions such as drug frequency statistics and simple compatibility analysis. They lack targeted analytical dimensions that align with the characteristics of TCM diagnosis and treatment (such as the correspondence between syndrome types and medications, the patterns of medication changes at different disease stages, and the correlation between drug dosage and symptom improvement). Furthermore, they cannot automatically generate multi-dimensional linked analysis data, making it difficult to uncover deep-seated medication patterns hidden in massive amounts of case / prescription data, and thus failing to provide strong support for optimizing TCM clinical diagnosis and treatment and developing prescriptions.
[0036] 4. Insufficient ease of use and poor versatility: Most existing tools require manual configuration of analysis parameters and selection of analysis models, which requires a high level of professional skills from the operators. For non-professional technical personnel such as TCM clinicians and researchers, the operation threshold is extremely high. They cannot meet the convenient use requirements of "one-click import, automatic processing, and rapid output", and have poor versatility, making it difficult to promote and apply them widely.
[0037] 5. The visualization is not practical enough and lacks the ability to extract data in depth and provide AI-assisted analysis: The visualization technology of the present technology can only realize the basic data surface display. It cannot further extract, filter and analyze the displayed medication-related data, and it does not provide AI-assisted analysis of medication chart information. It cannot mine potential correlations based on visualized data, generate analysis suggestions or treatment references, lack in-depth interpretation and decision support, and it is difficult to help users discover medication patterns and deduce treatment ideas, thus failing to give full play to its core role.
[0038] This application proposes a visualization analysis system and method for TCM case data, aiming to overcome the shortcomings of existing TCM medication data analysis technologies, such as cumbersome data processing, fragmented processes, limited analysis dimensions, and insufficient convenience. It provides a TCM medication data analysis tool that enables one-click full-process processing of case import, automatic cleaning, automatic generation of multi-dimensional analysis data, and visualization output, thereby improving analysis efficiency, comprehensiveness, and convenience, and providing efficient technical support for TCM medication research.
[0039] The technical solutions of the embodiments of this application and how the technical solutions of the embodiments of this application solve the above-mentioned technical problems will be described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that the various embodiments or technical features described below can be arbitrarily combined to form new embodiments. The order of description of the embodiments below is not intended to limit the preferred order of embodiments. The same or similar concepts or processes may not be described again in some embodiments. Obviously, the described embodiments are some embodiments of the embodiments of this application, but not all embodiments.
[0040] Example 1.
[0041] See Figure 1 This embodiment provides a visualization and analysis system for traditional Chinese medicine case data, including: The data analysis module is used to analyze medication patterns based on the standardized data corresponding to the raw data input by the user (such as structured TCM case / prescription data processed by the pre-processing cleaning module), and to generate a multi-dimensional analysis dataset by calling a preset multi-dimensional analysis model. The multi-dimensional analysis model includes a conventional analysis model and an original analysis model. The original analysis model is a medication change analysis model for multiple treatments of the same disease. It is used to analyze the medication adjustment patterns and symptom changes of patients with the same disease who have visited the hospital multiple times, according to the order of their visits.
[0042] The visualization output module is used to generate and output visualization charts or visualization reports based on the multi-dimensional analysis dataset and preset visualization templates.
[0043] The conventional analysis models include drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis models. The proprietary analysis model, when used, first filters data from patients who have visited the same clinic multiple times for the same disease, obtaining the drug changes for each patient at the second, third, and Nth visits. Then, it statistically analyzes the proportions of drug increases, decreases, and reductions for all patients from the first to the Nth visits to examine the patterns of drug changes across multiple visits for the same disease. N is a positive integer greater than 3.
[0044] The technical solution adopts a three-layer architecture of data-driven, model analysis, and visualization output: the input layer is used to receive standardized data (structured TCM case / prescription data processed by the pre-cleaning module), the analysis layer is used to perform in-depth mining of the standardized data through a preset multi-dimensional analysis model, and the output layer matches the analysis results with visualization templates to generate intuitive charts or reports.
[0045] To address the limitation of visualization tools that can only display single or fixed dimensions, a pre-set multi-dimensional analysis model is adopted to achieve full coverage of analysis dimensions. Recognizing the issues of cumbersome operation processes requiring manual parameter configuration by professional technicians, and the separation of data processing, pattern analysis, and visualization into different modules without end-to-end integration, the conventional analysis model covers basic dimensions, while the unique analysis model has pre-set analysis logic for scenarios involving multiple visits for a single disease, all without requiring user parameter configuration; the three-dimensional linkage analysis of time series, syndrome type, and medication automatically uncovers deep patterns; and the pre-set matching visualization templates achieve multi-dimensional visualization effects without manual adjustments.
[0046] Therefore, this invention effectively solves the technical problems existing in traditional Chinese medicine drug analysis, such as single analysis dimension, fragmented process, insufficient operation convenience, and lack of multi-dimensional visualization effect, through the data analysis module and visualization output module.
[0047] The rules for dividing the diagnosis and treatment stages include, for example: initial diagnosis is the first visit of a patient to this single disease without a clear long-term treatment plan; follow-up visit is the visit within a preset time interval after the initial diagnosis, where there are significant changes in symptoms or syndrome types and medication needs to be adjusted; and consolidation period is the visit after the follow-up visit where symptoms are basically relieved, syndrome types tend to be stable, and the purpose is to consolidate the therapeutic effect.
[0048] In practical applications, the multi-dimensional analysis model adopts a two-layer nested modular architecture. The outer layer serves as a model container, providing the runtime environment and resource scheduling for the data analysis module. The inner layer consists of two parallel and independent functional sub-modules: a conventional analysis model and a proprietary analysis model, which are mounted within the model container through a standardized interface. These two sub-modules are parallel and share the same standardized data source, operating independently but in parallel. Each analysis unit within the sub-module (drug frequency analysis unit, medicinal property and flavor ratio analysis unit, meridian tropism ratio analysis unit, drug relationship network analysis unit, drug correlation thermodynamic analysis unit, and drug clustering analysis unit) is encapsulated as a plug-in module and mounted to the data analysis module through a unified model registration interface.
[0049] In one exemplary embodiment, the visualization analysis system further includes: The data import module is used to receive raw data imported by the user. The raw data includes TCM medical records and / or prescriptions of multiple patients. The raw data can include HIS (Hospital Information System) data or medical record image data. The cleaning and processing module is used to standardize the raw data, obtain standardized data, and send it to the data analysis module.
[0050] In an exemplary embodiment, the process by which the cleaning module standardizes the raw data includes: Based on a pre-defined cleaning rule base and in accordance with a standard terminology dictionary, descriptions in the original data that are inconsistent with the disease and medication names in the standard terminology dictionary are screened, identified, and replaced. The original case data, after being screened, identified, and replaced, is split and populated to output standardized structured data.
[0051] The standard terminology dictionary includes, for example, the *Classification and Codes of Diseases and Syndromes in Traditional Chinese Medicine*, the *Pharmacopoeia of the People's Republic of China*, and the *Dictionary of Traditional Chinese Medicine*. A pre-defined cleaning rule base is established, and by comparing these rules with the standard terminology dictionary (*Classification and Codes of Diseases and Syndromes in Traditional Chinese Medicine*, *Pharmacopoeia of the People's Republic of China*, and *Dictionary of Traditional Chinese Medicine*), descriptions in the case data that do not match the names of symptoms and medications in the dictionary are screened and identified. Furthermore, matching rules can be supplemented by TCM professionals to complete the standardized matching mapping of no less than 3,000 common symptoms and TCM names; and anomalies such as unmatched terms appearing in subsequent case data are identified and reported, enabling dynamic updates of the standard terminology dictionary and the pre-defined cleaning rule base.
[0052] In an exemplary embodiment, the conventional analysis model is configured to perform at least one of the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis (and corresponding to their respective models), and generate corresponding analysis data.
[0053] See Figures 6 to 11 It can be assumed that the conventional analysis model integrates existing mature TCM drug analysis dimensions to achieve the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, drug cluster analysis, and generates analysis data (analysis graphs).
[0054] ① The core logic of drug frequency analysis is to statistically analyze the frequency of occurrence, cumulative dosage and frequency percentage of each drug in all cases corresponding to the same disease, clarify the priority ranking of core drugs and commonly used drugs in the treatment of the disease, and provide frequency reference for clinical drug use, which is displayed in a bar chart. ② The core logic of the drug property and flavor ratio analysis is based on the drug property (cold, hot, warm, cool, neutral) and flavor (sour, bitter, sweet, pungent, salty, etc.) recorded in the standard terminology dictionary. It statistically analyzes the proportion and distribution of each drug property and flavor in the medication for the same disease, analyzes the drug property compatibility rules and flavor combination characteristics for the treatment of the disease, and displays them in a radar chart. ③ The core logic of the meridian tropism ratio analysis is to statistically analyze the number and frequency of each meridian-tropy drug used in the same disease treatment based on the meridian tropism (heart, liver, spleen, lung, kidney, etc.) attribute of each drug in the standard terminology dictionary, explore the distribution pattern of drug meridian tropism in the treatment of the disease, clarify the organ-targeting characteristics of drug action, and display it in a bar chart. ④ The core logic of drug relationship network analysis is to use drugs as nodes and drug compatibility and co-occurrence relationships as edges, quantify the co-occurrence frequency and correlation strength of each drug, construct a drug compatibility relationship network, intuitively present the compatibility relationship of core drugs and auxiliary drugs, clearly show the compatibility logic and combination rules of clinical drug use, and display it in a circular relationship network diagram. ⑤ The core logic of drug association heat analysis is to construct an association matrix with drugs as rows and drugs as columns, map the co-occurrence frequency or association coefficient between drugs into heat values, and intuitively present the degree of association between different drugs through heat maps, which facilitates the rapid identification of high-frequency compatibility combinations and potential compatibility associations, and is displayed in a rectangular heat map. ⑥ Drug clustering analysis uses the K-means clustering algorithm. The core logic is to use drug efficacy, frequency of use, and meridian tropism as feature vectors to extract and standardize the features of drugs included in the analysis. An initial number of clusters is set (manual adjustment and optimization are supported). Through iterative calculation, the feature similarity of drugs within each cluster and the feature difference of drugs between clusters are maximized. Finally, drugs with similar efficacy, similar application scenarios, and consistent meridian tropism are grouped into one category. This helps to realize the systematic classification of drugs and the discovery of clinical drug use patterns. At the same time, it provides clustering reference for medication recommendations for new cases and is displayed as a tree-like clustering diagram.
[0055] In one exemplary embodiment, the original analysis model is a model for analyzing changes in medication use during multiple treatments for the same disease, and is configured as follows: Patients with the same single disease and multiple medical records are selected as target patients. Their complete medical and medication data are filtered. Using the order of medical visits as the axis, medication changes for each patient are extracted from their second, third, up to Nth visits compared to previous visits, specifically including increases, decreases, and stagnation in each medication. Statistical analysis is performed on the medication change data of all target patients at different numbers of visits, calculating the percentage increase, decrease, and stagnation for each medication at the corresponding number of visits, and counting the number of case groups involved. After sorting by the number of cases in descending order, the medications with the highest percentages are selected, generating a medication change dataset with the number of visits as the dimension, medication name as the category, and percentage change as the numerical value. Based on this dataset, the percentage increase, decrease, and stagnation of the top M medications at a specified number of visits is visualized. The dataset also supports switching between different number of visits and adjusting the number of displayed medications, ultimately uncovering the medication change patterns of multiple visits for the same disease. N and M are positive integers not less than 3.
[0056] As an example, this original analytical model can be used to analyze the medication patterns of single diseases in traditional Chinese medicine. Its core purpose is to focus on the changes in medication dosage at different times of visits for patients with the same single disease who have visited multiple times. By statistically analyzing the proportions of medication increases, decreases, and unchanged dosages for all patients, it can intuitively present the characteristics of medication changes at multiple visits for the same disease. This provides data support for identifying the core drugs for clinical medication adjustments and summarizing standardized medication patterns, and solves the problem in traditional analysis that it is difficult to quantify and display the proportion of medication changes at different stages of treatment.
[0057] See Figure 12 In one exemplary embodiment, the core execution logic of the original analysis model is as follows: Data filtering: Only retain patient data for the same single disease with two or more medical records to ensure the validity of the analysis sample; Change extraction: Based on the first visit, extract the changes in medications at the 2nd, 3rd...Nth visits, and mark the "increase / decrease / stable" status of each medication; N is a positive integer greater than 3; Statistical calculation: Summarize the changes in medication status for all patients, calculate the percentage change of each medication under the corresponding number of visits (increase percentage = number of increased cases / total number of cases × 100%, decrease / no change percentage is the same, and will not be elaborated further), and count the total number of case groups under that number of visits; Sorting and Display: Drugs are sorted in descending order by the number of cases. The top M drugs are selected and their percentage of increase, decrease, or stability is displayed in a visual chart (horizontal bar chart). It also supports dynamically switching the number of visits and adjusting the number of drugs displayed. Pattern Mining: Through multi-dimensional visualization analysis, we summarize the core medication adjustment patterns for the same disease at different stages of treatment.
[0058] In one exemplary embodiment, the statistical rule for the percentage change in medication use is as follows: Increase percentage: The percentage of cases where a certain drug was added or the dosage was increased during a specified number of visits, out of the total number of cases during that number of visits; Reduction percentage: The percentage of cases in which a certain drug was discontinued / reduced in a specified number of visits out of the total number of cases in that number of visits; Balanced percentage: The percentage of cases whose status remained unchanged during a specified number of visits for a certain drug, out of the total number of cases in that number of visits; the increase / decrease balance percentage for all drugs is calculated based on the number of valid cases in the corresponding number of visits, and the number of cases must be displayed synchronously in the visualization results.
[0059] See Figure 13 In one exemplary embodiment, the visualization output module includes: An operation acquisition unit for acquiring the user's interaction operations, where the interaction operations include switching the number of visits, adjusting the number of displayed drugs, clicking on a data item to view the corresponding case information, and filtering data by disease type for the multi-dimensional analysis data set; An information output unit for obtaining a corresponding visualization template according to the interaction operation as a target template, and generating and outputting a visualization chart or a visualization report according to the data selected by the target template and the interaction operation.
[0060] As an example, a specific example of the technical solution provided in Embodiment 1 is given. Taking the visualization system as a traditional Chinese medicine medication data analysis tool, its overall architecture includes the following core modules, and each module works together to achieve full-process automated processing: A data import module: responsible for receiving the original traditional Chinese medicine case / prescription data imported by the user, supporting multiple data formats (such as HIS case data, Excel, case pictures, etc.), supporting batch import and single-item import, and having a format verification function; A cleaning and processing module: receiving the imported original data, completing data cleaning, duplicate removal, term normalization, and structuring processing according to preset rules, and outputting standardized data; A data analysis module: receiving the standardized data, calling preset analysis models (including conventional analysis models and original analysis models), and automatically generating multi-dimensional analysis data; A visualization output module: receiving the multi-dimensional analysis data, matching the preset visualization template, and automatically generating a visualization chart; Among them, the data import module supports the import and format verification of traditional Chinese medicine case / prescription data in multiple formats, ensuring that the data can be processed by subsequent modules.
[0061] The cleaning and processing module automatically completes the cleaning, duplicate removal, term normalization, and structuring processing of the original data without manual intervention, solving the problem of non-standardization of traditional Chinese medicine data.
[0062] Among them, data cleaning is to automatically identify and process the noise data (such as garbled characters, invalid characters, repeated spaces, meaningless text) in the original data through a preset cleaning rule library. Specific rules include, for example, a garbled character replacement rule, an invalid character filtering rule, and a space compression rule; Data duplicate removal is to automatically identify and delete duplicate data based on preset duplicate removal keywords (such as case number, prescription number, patient name + visit time, etc.). The duplicate removal strategy is, for example, to retain the first piece of data, mark the duplicate data, and record it; Term normalization is for traditional Chinese medicine characteristic terms (symptoms, syndrome types, drugs, prescription names). Based on a preset term dictionary library (including national standard / industry standard term mapping relationships), non-standard terms are automatically normalized to standard terms. For example, "roasted mulberry bark" is normalized to "mulberry bark"; Structured processing involves splitting and filling normalized unstructured text data according to a preset data structure (fields include, for example, case number, patient basic information, consultation time, disease, medication, and medication dosage), and outputting standardized structured data (format, for example, JSON / database table structure). The abnormal data handling feature automatically marks and stores abnormal data that cannot be normalized or structured, prompting the user to manually review it (optional), without affecting the overall process operation.
[0063] Key parameters include cleaning efficiency (e.g., cleaning time for a single data entry ≤ 0.5 seconds, cleaning time for 1000 data entries ≤ 10 minutes); normalized accuracy (e.g., ≥ 95%); and deduplication accuracy (e.g., ≥ 99%).
[0064] The data analysis module receives structured data, automatically calls conventional and proprietary analysis models, and generates multi-dimensional TCM medication analysis data without requiring manual parameter configuration.
[0065] The visualization output module includes various built-in visualization templates, covering bar charts, horizontal bar charts, relationship network diagrams, heatmaps, cluster diagrams, radar charts, etc., facilitating citations in research papers and reports. It supports further extraction and filtering of the visualized data; users can click on any drug item in the chart to quickly extract details such as the number of corresponding cases and the percentage increase or decrease. It also supports switching between different visit frequencies and adjusting the number of displayed drugs to focus on the target analysis content.
[0066] As an example, the implementation steps of the original analysis model are as follows: ① Screening of patients with the same disease who have visited the clinic multiple times: From the automatically cleaned structured data, patients with the same single disease who have visited the clinic twice or more are screened to form a target patient dataset; ② Medication Change Extraction: Using the order of consultation time as the axis, extract the changes in medication for each patient from the second, third, up to the Nth consultation compared to the previous consultation, and mark each drug as increased, decreased, or unchanged. ③ Statistics on the percentage of changes in medication use: Summarize the changes in medication use for all target patients at the corresponding number of visits, calculate the percentage increase, percentage decrease, and percentage remain unchanged for each drug, and count the number of case groups at that number of visits; ④ Sorting and Visualization Dataset Generation: Sort by number of cases in descending order, select the top-ranked drugs, and generate a medication change dataset with the structure of visit frequency - drug name - percentage of change; ⑤ Visualization and Pattern Output: Based on this medication change dataset, a horizontal bar chart is used to display the percentage of increase, decrease, and stagnation of medications under a specified number of visits. It supports switching the number of visits and adjusting the number of displayed medications, and finally mines and outputs the medication change patterns of the same disease after multiple visits.
[0067] After following the steps above, the following results can be obtained: ① Summary table of medication changes across multiple visits for the same disease: including the number of case groups for each number of visits, and the percentage of each drug showing an increase / decrease / remaining unchanged; ② Comparison chart of medication changes across multiple visits (e.g.) Figure 14 ① Supports switching between the 2nd, 3rd... Xth visits, intuitively displaying medication adjustment trends; ② High-frequency adjustment medication list: clearly identifies the medications that are most frequently added, most frequently reduced, and most frequently remain unchanged at each stage of treatment; ③ Summary of medication change patterns: provides data support for standardized diagnosis and treatment of single diseases in traditional Chinese medicine and the formulation of individualized medication plans.
[0068] As another example, the system provided in this embodiment serves as a platform, and its overall operation flow is as follows: Step 1: Launch this platform, enter the data import interface, select the import method (local import / batch import / online paste), select the TCM case / prescription data to be imported, click the "Import" button to complete the data import, the system will automatically complete the preliminary data verification and mark abnormal data; Step 2: The user checks the imported data and anomaly markers, chooses to ignore the abnormal data or correct and re-import. After confirming that there are no errors, click the "Automatic Cleaning" button. The system starts the automatic cleaning module and completes data deduplication, terminology normalization, and format unification according to preset rules. After the processing is completed, a cleaning report is generated. Step 3: After the user verifies the cleaning report and confirms that the data processing is correct, click the "One-Click Analysis" button. The system will start the data analysis module and automatically complete the analysis of conventional and unique dimensions. After the analysis is completed, a multi-dimensional analysis dataset will be generated. Step 4: After the analysis is completed, the system will automatically redirect to the visualization display interface. Users can select the visualization display type, switch the number of visits, adjust the number of drugs displayed, and view drug details. Step 5: Users can export visualization charts, analysis reports, and structured data, and can also store the analysis results in the backend database for easy retrieval and reuse later; Therefore, the above steps utilize standardized design of data interfaces between modules to achieve seamless connection of the entire process from data import to automatic cleaning, multi-dimensional analysis, and visualization output. The modules adopt a real-time data transmission mechanism, eliminating the need for users to manually switch modules or import / export data. A one-click processing button is provided, so after the user completes the data import, for example, by clicking the "one-click analysis" button on the page, the system automatically triggers the operation of all modules without any manual intervention.
[0069] Furthermore, a modular integrated design is adopted, integrating conventional analysis models and original analysis models into the same module. Through a unified data call interface, the model and the cleaned data can be quickly matched. The model supports dynamic updates and additions, and users can add custom analysis models according to their own research needs, thereby improving the platform's scalability.
[0070] The technical solution provided in this embodiment has been shown by experiments to take no more than 15 minutes (1000 case data) from data import to the generation of visualization results. To ensure that those skilled in the art can accurately reproduce this invention, the following key parameters are set: (1) OCR recognition parameters: recognition accuracy ≥ 95%, recognition speed ≥ 10 images / minute (image format data); (2) Data processing parameters: single processing data volume ≤ 1000 cases / batch, processing time ≤ 10 minutes / batch, data processing error rate ≤ 1%; (3) Analysis model parameters: drug change statistical accuracy ≥ 98%, proportion calculation error ≤ 1%; (4) Storage parameters: supports a maximum data storage capacity of ≥ 1 million case / prescription data, data retrieval response time ≤ 1 second.
[0071] As another example, an implementation scenario of the technical solution provided in this embodiment is provided, which is used for analyzing the changes in medication use during multiple visits for a single disease in a hospital using traditional Chinese medicine. The implementation conditions are as follows: Hardware environment: CPU Intel i7-12700H, memory 16GB, hard disk 512GB, operating system Windows 11; Software environment: programming language Python 3.9, database MySQL 8.0, visualization library ECharts 5.4, development framework Django 4.2; Test data: 15,000 anonymized TCM prescriptions (format: Excel, including multiple visit records).
[0072] The implementation steps are as follows: Data import: Batch import Excel data of multiple visits for a single disease / prescription; the system automatically performs format verification. Automatic cleaning process: Automatically calls the cleaning process module to complete data cleaning, deduplication, terminology normalization, and structured processing, and outputs standardized data; Multi-dimensional automatic analysis: The system automatically calls the data analysis module and runs both the conventional analysis model and the analysis model of changes in medication use during multiple treatments for the same disease. It automatically calculates the percentage of increases, decreases, and unchanged medication use and the number of cases for each number of visits. Visual output: The system automatically generates horizontal bar charts to show the changes in medication at the 2nd, 3rd... Nth visit, and supports switching between views, exporting charts and reports.
[0073] The implementation results are as follows: This example can quickly and accurately uncover the medication adjustment patterns of patients who have visited the same disease multiple times at different stages of treatment, improving efficiency by more than 95% compared to traditional manual statistical methods; the analysis results are highly consistent with clinical practice, providing real and reliable data support for optimizing TCM clinical medication and formulating treatment guidelines.
[0074] Therefore, the technical solution provided in this embodiment achieves one-click automated processing throughout the entire process, eliminating the need for manual intervention in data cleaning, parameter configuration, and model switching, significantly improving processing efficiency and accuracy; it integrates conventional and original analysis dimensions to uncover deep-seated medication patterns; it has a low operating threshold, requiring no professional technicians, and users only need to import data to automatically obtain analysis results and visualization reports; it supports the import of data in multiple formats, adapting to different diseases and data sources, and has strong versatility and wide application scenarios.
[0075] Example 2.
[0076] See Figure 2 This embodiment provides a method for visual analysis of TCM case data. Its specific implementation and the technical effects achieved are consistent with those described in the above-mentioned method embodiments, and some details will not be repeated. The method includes: S103: Based on the standardized data corresponding to the raw data input by the user, call the preset multi-dimensional analysis model to perform medication pattern analysis and generate a multi-dimensional analysis dataset; S104, Based on the multi-dimensional analysis dataset and the preset visualization template, generate and output a visualization chart or visualization report; The multi-dimensional analysis model includes a conventional analysis model and an original analysis model. The original analysis model is a medication change analysis model for multiple treatments of the same disease. It is used to analyze the medication adjustment patterns and symptom changes of patients with the same disease who have visited multiple times, according to the order of their visits.
[0077] See Figure 3 In one exemplary embodiment, the method further includes: S101, Receive raw data imported by the user, the raw data including multiple patients' TCM medical records and / or prescriptions; S102, Standardize the original data to obtain standardized data.
[0078] See Figure 4 In one exemplary embodiment, the process of standardizing the raw data includes: S201, based on the preset cleaning rule library and in accordance with the standard terminology dictionary library, filters, identifies and replaces descriptions in the original data that are inconsistent with the disease and medication names in the standard terminology dictionary library; S202 splits and populates the original case data after screening, identification, and replacement, and outputs standardized structured data.
[0079] In an exemplary embodiment, the conventional analysis model is configured to perform at least one of the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis, and generate corresponding analysis data.
[0080] In one exemplary embodiment, the original analysis model is configured as follows: Patients with the same single disease and multiple medical records were selected as target patients, and their complete medical and medication data were screened. Using the order of visit time as the axis, extract the medication change information of each patient from the second, third, up to the Nth visit compared to the previous visit. The medication change information includes the changes of each drug, such as increase, decrease, or no change. Statistical analysis was performed on the changes in medication use of all target patients under different number of visits, calculating the percentage increase, decrease, and no change for each drug under the corresponding number of visits, and the number of case groups involved was counted. After sorting by the number of cases in descending order, the drugs with the highest percentages were selected, and a medication change dataset was generated with the number of visits as the dimension, drug name as the category, and percentage change as the numerical value. Based on the aforementioned medication change dataset, the percentage of increases, decreases, and unchanged rates for the top M drugs under a specified number of visits is visualized.
[0081] See Figure 5 In one exemplary embodiment, generating and outputting a visualization chart or visualization report based on the multi-dimensional analysis dataset and a preset visualization template includes: S301, Obtain user interaction operations; the interaction operations include, for the multi-dimensional analysis dataset, switching the number of visits, adjusting the number of displayed drugs, clicking on data items (case information list) to view corresponding case information, and filtering data by disease type; S302, obtain the corresponding visualization template according to the interactive operation and use it as the target template, generate a visualization chart or visualization report according to the target template and the data selected by the interactive operation and output it.
[0082] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the embodiments of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application. Any changes or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the protection scope of this application.
Claims
1. A visualization and analysis system for traditional Chinese medicine case data, characterized in that, include: The data analysis module is used to analyze medication patterns by calling a preset multi-dimensional analysis model based on the standardized data corresponding to the raw data input by the user, and to generate a multi-dimensional analysis dataset. The multi-dimensional analysis model includes a conventional analysis model and an original analysis model. The original analysis model is a medication change analysis model for multiple treatments of the same disease. It is used to analyze the medication adjustment patterns and symptom changes of patients with the same disease who have visited the hospital multiple times, according to the order of their visits. The visualization output module is used to generate and output visualization charts or visualization reports based on the multi-dimensional analysis dataset and preset visualization templates.
2. The visualization analysis system according to claim 1, characterized in that, The visualization analysis system also includes: The data import module is used to receive raw data imported by the user, which includes multiple patients' TCM medical records and / or prescriptions; The cleaning and processing module is used to standardize the raw data, obtain standardized data, and send it to the data analysis module.
3. The visualization analysis system according to claim 2, characterized in that, The process by which the cleaning module standardizes the raw data includes: Based on a pre-defined cleaning rule base and in accordance with a standard terminology dictionary, descriptions in the original data that are inconsistent with the disease and medication names in the standard terminology dictionary are screened, identified, and replaced. The original case data, after being screened, identified, and replaced, is split and populated to output standardized structured data.
4. The visualization analysis system according to claim 1, characterized in that, The conventional analysis model is configured to perform at least one of the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis, and generate corresponding analysis data.
5. The visualization analysis system according to claim 1, characterized in that, The original analytical model is configured as follows: Patients with the same single disease and multiple medical records were selected as target patients, and their complete medical and medication data were screened. Using the order of visit time as the axis, extract the medication change information of each patient from the second, third, up to the Nth visit compared to the previous visit. The medication change information includes the changes of each drug, such as increase, decrease, or no change. Statistical analysis was performed on the changes in medication use of all target patients under different number of visits, calculating the percentage increase, decrease, and no change for each drug under the corresponding number of visits, and the number of case groups involved was counted. After sorting by the number of cases in descending order, the drugs with the highest percentages were selected, and a medication change dataset was generated with the number of visits as the dimension, drug name as the category, and percentage change as the numerical value. Based on the aforementioned medication change dataset, the percentage of increases, decreases, and unchanged rates for the top M drugs under a specified number of visits is visualized.
6. The visualization analysis system according to claim 1, characterized in that, The visualization output module includes: An operation acquisition unit is used to acquire user interaction operations, including switching the number of visits, adjusting the number of displayed drugs, clicking on data items to view corresponding case information, and filtering data by disease for the multi-dimensional analysis dataset. The information output unit is used to obtain the corresponding visualization template based on the interactive operation and use it as the target template, and to generate and output the visualization chart or visualization report based on the target template and the data selected by the interactive operation.
7. A method for visual analysis of traditional Chinese medicine case data, characterized in that, include: Based on the standardized data corresponding to the raw data input by the user, a preset multi-dimensional analysis model is invoked to analyze medication patterns and generate a multi-dimensional analysis dataset. Based on the multi-dimensional analysis dataset and the preset visualization template, generate and output visualization charts or visualization reports; The multi-dimensional analysis model includes a conventional analysis model and an original analysis model. The original analysis model is a medication change analysis model for multiple treatments of the same disease. It is used to analyze the medication adjustment patterns and symptom changes of patients with the same disease who have visited multiple times, according to the order of their visits.
8. The visualization analysis method according to claim 7, characterized in that, The conventional analysis model is configured to perform at least one of the following automated analyses: drug frequency analysis, drug property and flavor ratio analysis, meridian tropism ratio analysis, drug relationship network analysis, drug correlation heat analysis, and drug cluster analysis, and generate corresponding analysis data.
9. The visualization analysis method according to claim 7, characterized in that, The original analytical model is configured as follows: Patients with the same single disease and multiple medical records were selected as target patients, and their complete medical and medication data were screened. Using the order of visit time as the axis, extract the medication change information of each patient from the second, third, up to the Nth visit compared to the previous visit. The medication change information includes the changes of each drug, such as increase, decrease, or no change. Statistical analysis was performed on the changes in medication use of all target patients under different number of visits, calculating the percentage increase, decrease, and no change for each drug under the corresponding number of visits, and the number of case groups involved was counted. After sorting by the number of cases in descending order, the drugs with the highest percentages were selected, and a medication change dataset was generated with the number of visits as the dimension, drug name as the category, and percentage change as the numerical value. Based on the aforementioned medication change dataset, the percentage of increases, decreases, and unchanged rates for the top M drugs under a specified number of visits is visualized.
10. The visualization analysis method according to claim 7, characterized in that, The process of generating and outputting visual charts or reports based on the multi-dimensional analysis dataset and preset visualization templates includes: The user's interactive operations are obtained, including switching the number of visits, adjusting the number of displayed drugs, clicking on data items to view corresponding case information, and filtering data by disease for the multi-dimensional analysis dataset. The corresponding visualization template is obtained based on the interactive operation and used as the target template. Based on the target template and the data selected by the interactive operation, a visualization chart or visualization report is generated and output.