CN112732786A - Financial data processing method, device, equipment and storage medium - Google Patents

Financial data processing method, device, equipment and storage medium Download PDF

Info

Publication number
CN112732786A
CN112732786A CN202011635804.0A CN202011635804A CN112732786A CN 112732786 A CN112732786 A CN 112732786A CN 202011635804 A CN202011635804 A CN 202011635804A CN 112732786 A CN112732786 A CN 112732786A
Authority
CN
China
Prior art keywords
financial
financial data
data
data processing
model
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202011635804.0A
Other languages
Chinese (zh)
Inventor
代心灵
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN202011635804.0A priority Critical patent/CN112732786A/en
Priority to PCT/CN2021/084256 priority patent/WO2022141877A1/en
Publication of CN112732786A publication Critical patent/CN112732786A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2458Special types of queries, e.g. statistical queries, fuzzy queries or distributed queries
    • G06F16/2474Sequence data queries, e.g. querying versioned data
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q40/00Finance; Insurance; Tax strategies; Processing of corporate or income taxes

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Development Economics (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • General Engineering & Computer Science (AREA)
  • Probability & Statistics with Applications (AREA)
  • Mathematical Physics (AREA)
  • Fuzzy Systems (AREA)
  • Accounting & Taxation (AREA)
  • Computational Linguistics (AREA)
  • Economics (AREA)
  • Finance (AREA)
  • Marketing (AREA)
  • Strategic Management (AREA)
  • Technology Law (AREA)
  • General Business, Economics & Management (AREA)
  • Financial Or Insurance-Related Operations Such As Payment And Settlement (AREA)

Abstract

The invention relates to the field of artificial intelligence and discloses a financial data processing method, device, equipment and storage medium. The method comprises the following steps: acquiring user financial data to be predicted, market financial data and enterprise financial data, and preprocessing the user financial data and the enterprise financial data to obtain financial index data; matching the financial index data with the financial data to obtain a plurality of contemporaneous financial data, and performing univariate analysis to obtain average financial data; inputting the average financial data and the financial data into a financial data processing model set to respectively predict the financial data to obtain the distribution weight and the financial predicted value of each prediction model; normalizing the financial predicted value to obtain new financial data of the user; and determining the change trend of the financial data of the user corresponding to the next period according to the difference value of the financial data of the user for two times. The invention introduces the connection among the multi-party data into the financial data processing model set, and improves the prediction accuracy.

Description

Financial data processing method, device, equipment and storage medium
Technical Field
The invention relates to the field of artificial intelligence, in particular to a financial data processing method, device, equipment and storage medium.
Background
With the development of artificial intelligence, the financial industry increasingly uses artificial intelligence to perform intelligent analysis, and provides strengthened data scientific support for financial decisions. In traditional financial forecast of listed companies, only the forecast of self stock valuation and the like is concerned, the personalized emotion of investors is ignored, the value of self stocks is improved for a long time, and more attention is not paid to how to provide good user investment experience for the investors, so that the investors are more stable and the like.
Financial data as one of time data sequences has strong timeliness and periodicity, the data sequences often have deep dependencies before and after the data sequences, and the characteristics enable the trend of financial prediction to become possible, and the trend is a hot spot and a difficult point of the current financial prediction. The traditional method usually adopts a single deep learning model for prediction, so that the prediction difficulty is high, and the accuracy of the prediction result is not high.
Disclosure of Invention
The invention mainly aims to solve the technical problem of improving the prediction accuracy of a machine learning model.
The invention provides a financial data processing method in a first aspect, which comprises the following steps:
acquiring market financial data and enterprise financial data in a time series format and first user financial data corresponding to the current period;
preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
performing synchronous data matching on the first financial index data and the first user financial data to obtain a plurality of first synchronous financial data, and performing univariate analysis on the first synchronous financial data to obtain first average financial data;
inputting the first average financial data and the first user financial data into a preset financial data processing model set to respectively predict financial data, so as to obtain distribution weights corresponding to the data processing models in the financial data processing model set and first financial predicted values output by the data processing models;
according to the distribution weight, performing normalization processing on the first financial predicted value output by each data processing model to obtain second user financial data corresponding to the next period;
and determining the user financial data change trend corresponding to the next period according to the difference value of the first user financial data and the second user financial data.
Optionally, in a first implementation manner of the first aspect of the present invention, before the acquiring the market financial data, the enterprise financial data, and the first user financial data corresponding to the current period in the time series format, the method further includes:
acquiring market financial data samples, enterprise financial data samples and user financial data samples corresponding to the appointed period of investors in a time series format;
preprocessing the market financial data sample and the enterprise financial data sample to obtain a plurality of second financial index data;
performing contemporaneous data matching on the second financial index data and the user financial data sample to obtain a plurality of second contemporaneous financial data, and performing univariate analysis on the second contemporaneous financial data to obtain second average financial data;
respectively inputting the second average financial data and the user financial data samples into a plurality of preset data processing training models to predict financial data, and obtaining a second financial predicted value output by each data processing training model and the goodness of fit of each data processing training model;
according to the second financial predicted value of each data processing training model, performing parameter optimization on each data processing training model until each data processing training model converges to obtain a plurality of data processing models;
and performing weighted Stacking integration on the plurality of data processing models according to the goodness of fit of each data processing training model to obtain a financial data processing model set comprising a plurality of data processing models.
Optionally, in a second implementation manner of the first aspect of the present invention, the performing parameter tuning on each data processing training model according to the second financial predicted value of each data processing training model until each data processing training model converges to obtain a plurality of data processing models includes:
calling a preset loss function, and respectively calculating the error rate of the second financial predicted value of each data processing model;
and according to the error rate, performing fitting parameter optimization on the data processing training models respectively until the data processing training models converge to obtain a plurality of data processing models.
Optionally, in a third implementation manner of the first aspect of the present invention, the preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data includes:
according to the market financial data and the enterprise financial data, carrying out data difference on the market financial data and the enterprise financial data to obtain a plurality of difference indexes;
carrying out synchronous amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of synchronous amplification indexes;
performing the up-date amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of up-date amplification indexes;
wherein the first financial index data includes the difference index, the contemporaneous amplification index, and the up-dated amplification index.
Optionally, in a fourth implementation manner of the first aspect of the present invention, the performing synchronization data matching on each piece of first financial index data and the first user financial data to obtain a plurality of pieces of first synchronization financial data, and performing univariate analysis on each piece of the first synchronization financial data to obtain the first average financial data includes:
time sequence alignment is carried out on the first financial index data and the first user financial data, and data corresponding to the same time are respectively taken for matching to obtain a plurality of first synchronous financial data;
calculating the average value of each first synchronous financial data in the corresponding investment period, and generating a univariate analysis chart corresponding to each first synchronous financial data according to the average value;
and performing characteristic screening on the univariate analysis chart to obtain first average financial data.
Optionally, in a fifth implementation manner of the first aspect of the present invention, the inputting the first average financial data and the first user financial data into a preset financial data processing model set to perform financial data prediction, respectively, and obtaining the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model includes:
inputting the first average financial data and the first user financial data into a preset financial data processing model set, wherein the financial data processing model set comprises an Xgboost model, a GBRT model, an Adaboost model, a DNN model and an LSTM model;
and respectively carrying out weight operation and next-period financial value operation through the Xgboost model, the GBRT model, the Adaboost model, the DNN model and the LSTM model to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model.
Optionally, in a sixth implementation manner of the first aspect of the present invention, the performing normalization processing on the first financial prediction values output by the data processing models according to the distribution weights to obtain second user financial data corresponding to a next period includes:
calculating a weighted financial predicted value of the first financial predicted values output by the data processing models according to the distribution weight;
and calling a preset normalization function, and performing normalization processing on the weighted financial investment predicted value to obtain second user financial data corresponding to the next period.
A second aspect of the present invention provides a financial data processing apparatus comprising:
the data acquisition module is used for acquiring market financial data, enterprise financial data and first user financial data corresponding to the current period in a time series format;
the preprocessing module is used for preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
the matching analysis module is used for carrying out synchronous data matching on the first financial index data and the first user financial data to obtain a plurality of first synchronous financial data, and carrying out univariate analysis on the first synchronous financial data to obtain first average financial data;
the data processing module is used for inputting the first average financial data and the first user financial data into a preset financial data processing model set to respectively predict financial data, so as to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and a first financial predicted value output by each data processing model;
the normalization module is used for performing normalization processing on the first financial predicted values output by the data processing models according to the distribution weights to obtain second user financial data corresponding to the next period;
a trend judging module for determining the change trend of the financial data of the user corresponding to the next period according to the difference value of the financial data of the first user and the financial data of the second user
Optionally, in a first implementation manner of the second aspect of the present invention, the financial data processing apparatus further includes:
the sample processing module is used for acquiring market financial data samples, enterprise financial data samples and user financial data samples corresponding to a specified period in a time series format; preprocessing the market financial data sample and the enterprise financial data sample to obtain a plurality of second financial index data; performing contemporaneous data matching on the second financial index data and the user financial data sample to obtain a plurality of second contemporaneous financial data, and performing univariate analysis on the second contemporaneous financial data to obtain second average financial data;
the sample prediction module is used for inputting the second average financial data and the user financial data samples into a plurality of preset data processing training models respectively to carry out financial data prediction so as to obtain a second financial prediction value output by each data processing training model and the goodness of fit of each data processing training model;
the model optimization module is used for respectively carrying out parameter optimization on each data processing training model according to the second financial predicted value of each data processing training model until each data processing training model converges to obtain a plurality of data processing models;
and the model integration module is used for performing weighted Stacking integration on the plurality of data processing models according to the goodness of fit of each data processing training model to obtain a financial data processing model set comprising a plurality of data processing models.
Optionally, in a second implementation manner of the second aspect of the present invention, the model optimization module is specifically configured to:
calling a preset loss function, and respectively calculating the error rate of the second financial predicted value of each data processing model;
and according to the error rate, performing fitting parameter optimization on the data processing training models respectively until the data processing training models converge to obtain a plurality of data processing models.
Optionally, in a third implementation manner of the second aspect of the present invention, the preprocessing module is specifically configured to:
according to the market financial data and the enterprise financial data, carrying out data difference on the market financial data and the enterprise financial data to obtain a plurality of difference indexes;
carrying out synchronous amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of synchronous amplification indexes;
performing the up-date amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of up-date amplification indexes;
wherein the first financial index data includes the difference index, the contemporaneous amplification index, and the up-dated amplification index.
Optionally, in a fourth implementation manner of the second aspect of the present invention, the matching analysis module is specifically configured to:
time sequence alignment is carried out on the first financial index data and the first user financial data, and data corresponding to the same time are respectively taken for matching to obtain a plurality of first synchronous financial data;
calculating the average value of each first synchronous financial data in the corresponding period, and generating a univariate analysis chart corresponding to each first synchronous financial data according to the average value;
and performing characteristic screening on the univariate analysis chart to obtain first average financial data.
Optionally, in a fifth implementation manner of the second aspect of the present invention, the data prediction module is specifically configured to:
inputting the first average financial data and the first user financial data into a preset financial data processing model set, wherein the financial data processing model set comprises an Xgboost model, a GBRT model, an Adaboost model, a DNN model and an LSTM model;
and respectively carrying out weight operation and next-period financial value operation through the Xgboost model, the GBRT model, the Adaboost model, the DNN model and the LSTM model to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model.
Optionally, in a sixth implementation manner of the second aspect of the present invention, the normalization module is specifically configured to:
calculating a weighted financial predicted value of the first financial predicted values output by the data processing models according to the distribution weight;
and calling a preset normalization function, and performing normalization processing on the weighted financial predicted value to obtain second user financial data corresponding to the next period.
A third aspect of the present invention provides a financial data processing apparatus comprising: a memory and at least one processor, the memory having instructions stored therein; the at least one processor invokes the instructions in the memory to cause the financial data processing apparatus to perform the financial data processing method described above.
A fourth aspect of the present invention provides a computer-readable storage medium having stored therein instructions, which, when run on a computer, cause the computer to execute the above-described financial data processing method.
In the technical scheme provided by the invention, in view of the low prediction accuracy of a single data processing model adopted in the existing financial data processing, a plurality of different data processing model sets are adopted for financial data prediction, firstly, the financial data of markets and enterprises and the financial data of users are obtained, the financial data of the markets and the enterprises are preprocessed and then matched with the financial data to obtain a plurality of contemporaneous financial data, then univariate analysis is carried out to obtain average financial data, and the connection among the markets, the enterprises and investors can be found by processing and analyzing a large amount of comprehensive data; and inputting the average financial data and the financial data into a preset financial data processing model set to respectively predict the financial data to obtain the distribution weight and the financial predicted value of each data processing model, and normalizing the financial predicted value to obtain new financial data. The invention adopts a model set integrated by a plurality of data processing models to predict the financial data, integrates the advantages of the plurality of data processing models and can lead the predicted value to be closer to the true value; and finally, determining the change trend of the financial data corresponding to the next period according to the difference value of the two financial data. According to the method, the financial data is predicted through the model set formed by the plurality of data processing models, and the accuracy of prediction is improved.
Drawings
FIG. 1 is a schematic diagram of a first embodiment of a financial data processing method in accordance with an embodiment of the present invention;
FIG. 2 is a schematic diagram of a financial data processing method according to a second embodiment of the present invention;
FIG. 3 is a schematic diagram of a first embodiment of a financial data processing apparatus according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of a financial data processing apparatus according to a second embodiment of the present invention
FIG. 5 is a schematic diagram of an embodiment of a financial data processing apparatus according to an embodiment of the present invention.
Detailed Description
The embodiment of the invention provides a financial data processing method, device, equipment and storage medium. The terms "first," "second," "third," "fourth," and the like in the description and in the claims, as well as in the drawings, if any, are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced otherwise than as specifically illustrated or described herein. Furthermore, the terms "comprises," "comprising," or "having," and any variations thereof, are intended to cover non-exclusive inclusions, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
For ease of understanding, a detailed flow of an embodiment of the present invention is described below, and referring to fig. 1, a first embodiment of a financial data processing method according to an embodiment of the present invention includes:
101. acquiring market financial data and enterprise financial data in a time series format and first user financial data corresponding to the current period;
it is understood that the executing subject of the present invention may be a financial data processing device, and may also be a terminal or a server, which is not limited herein. The embodiment of the present invention is described by taking a server as an execution subject.
In this embodiment, market financial data such as the number of certificates, the birth index, the dow jones index, the market company's daily stock index, the daily dollar to RMB exchange rate, the U.S. quarterly GDP, the Chinese quarterly GDP; the enterprise financial data such as the financial indexes of a certain listed company in some regions such as Asia, Europe, Japan proportion, financial amount and the like in a past period, the market net rate of the listed company in a period, the rating of the company recommended to buy and sell by an organization in a historical period of the listed company, and the like, the first investment financial data is the financial amount of the listed company held by an investor at present, and the data has a relation with the time sequence, so that the data can be used for judging the change trend of the future financial data.
102. Preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
in this embodiment, the preprocessing includes data difference, synchronization amplification comparison and previous amplification comparison, and the market financial data and the enterprise financial data may be obtained after the preprocessing.
Optionally, in an embodiment, the preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data includes:
according to the market financial data and the enterprise financial data, carrying out data difference on the market financial data and the enterprise financial data to obtain a plurality of difference indexes;
carrying out synchronous amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of synchronous amplification indexes;
performing the up-date amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of up-date amplification indexes;
wherein the first financial index data includes the difference index, the contemporaneous amplification index, and the up-dated amplification index.
In this embodiment, the data difference is, for example, that the index is a daily stock price, and the difference is a difference between the daily stock price and a last-period stock price; the synchronous amplification comparison is that the daily stock price ratio is increased in the same period of the last year; the last-stage amplification comparison is that the daily stock price ratio is amplified in the last stage, and a plurality of financial index data are obtained after the processing.
103. Performing synchronous data matching on the first financial index data and the first user financial data to obtain a plurality of first synchronous financial data, and performing univariate analysis on the first synchronous financial data to obtain first average financial data;
in this embodiment, the synchronization data matching is to perform corresponding value taking at a position corresponding to the time sequence, and for a certain user, a value of X on a certain date is matched to obtain a value of Y in the same period, which is a corresponding value. The single variable analysis obtains a continuous variable or a discrete variable, the continuous variable is that the variable value is continuous, the distribution of general variable values is more, such as the index of stock price, and can be continuously changed in a section of data range, and the discrete variable is that the variable only has a certain value, such as the index of investment style, and only has a plurality of styles, such as aggressive style, conservative style, stable growth style and the like.
Optionally, in an embodiment, the performing synchronization data matching on each piece of first financial index data and the first user financial data to obtain a plurality of pieces of first synchronization financial data, and performing univariate analysis on each piece of first synchronization financial data to obtain the first average financial data includes:
time sequence alignment is carried out on the first financial index data and the first user financial data, and data corresponding to the same time are respectively taken for matching to obtain a plurality of first synchronous financial data;
calculating the average value of each first synchronous financial data in the corresponding period, and generating a univariate analysis chart corresponding to each first synchronous financial data according to the average value;
and performing characteristic screening on the univariate analysis chart to obtain first average financial data.
In this embodiment, two extreme values of a variable are respectively set as a group during univariate analysis (one group is a percentile of < 5%, one group is a quantile of greater than 95%), box operations such as 5% -95% quantile and the like (the boxes are equal in length of the value interval of each group) are divided into n groups, then the average values of the n groups of data are respectively calculated to obtain a plurality of average data, when a certain variable is found to take a certain value according to an average data drawing curve, and the Avg _ threshold of the group is obviously higher or lower than the overall Avg _ threshold, binarization decoding is performed on the corresponding group of the variable, and when the decoding value of the variable is 1, average financial data is obtained.
104. Inputting the first average financial data and the first user financial data into a preset financial data processing model set to respectively predict financial data, so as to obtain distribution weights corresponding to the data processing models in the financial data processing model set and first financial predicted values output by the data processing models;
in this embodiment, the financial investment data prediction model set includes a plurality of prediction models, such as an Xgboost prediction model, a GBRT prediction model, an Adaboost prediction model, a DNN prediction model, and an LSTM prediction model, and each prediction model in the model set outputs a distribution weight and a financial investment prediction value corresponding to each model.
Optionally, in an embodiment, the inputting the first average financial data and the first user financial data into a preset financial data processing model set to perform financial data prediction, and obtaining the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial prediction value output by each data processing model includes:
inputting the first average financial data and the first user financial data into a preset financial data processing model set, wherein the financial data processing model set comprises an Xgboost model, a GBRT model, an Adaboost model, a DNN model and an LSTM model;
and respectively carrying out weight operation and next-period financial value operation through the Xgboost model, the GBRT model, the Adaboost model, the DNN model and the LSTM model to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model.
In this embodiment, each of the Xgboost model, the GBRT model, the Adaboost model, the DNN model, and the LSTM model includes an input layer, an activation function, and an output layer, and performs a financial investment value calculation according to the activation function in each data processing model, to obtain each predicted value and distribution weight in the next period. The construction process of each data processing model comprises the steps of setting a loss function, iteration times and parameter ranges; initializing model establishment, obtaining an error rate according to a loss function, and continuously iterating the model until the error of the model is converged; and outputting the predicted value and the distribution weight of the model.
105. According to the distribution weight, performing normalization processing on the first financial predicted value output by each data processing model to obtain second user financial data corresponding to the next period;
in this embodiment, the financial data processing model outputs the predicted value and simultaneously outputs the evaluation index of the model, and r2score in the evaluation index is subjected to standard weight processing to obtain the distribution weight.
Optionally, in an embodiment, the normalizing the first financial prediction value output by each data processing model according to the distribution weight to obtain second user financial data corresponding to a next period includes:
calculating a weighted financial predicted value of the first financial predicted values output by the data processing models according to the distribution weight;
and calling a preset normalization function, and performing normalization processing on the weighted financial predicted value to obtain second user financial data corresponding to the next period.
In this embodiment, it is assumed that the output values of the data processing models are respectively: y1, y2, y3, y4, y 5; the distribution weight corresponding to each data processing model is as follows: a1, a2, a3, a4, a 5. The weighted financial forecast is:
y1 a1, y2 a2, y3 a3, y4 a4, y5 a5 were normalized as: the user financial data was (y1 a1+ y2 a2+ y3 a3+ y4 a4+ y5 a 5).
106. And determining the user financial data change trend corresponding to the next period according to the difference value of the first user financial data and the second user financial data.
In this embodiment, when the financial data of the first user is 20000 and the financial data of the second user is 30000, the difference is made to-10000, so that the change trend of the financial data corresponding to the next period is rising; when the financial data of the first user is 20000 and the financial data of the second user is 20000, the difference is made to obtain 0, so that the variation trend of the financial data corresponding to the next period is unchanged; when the financial data of the first user is 20000 and the financial data of the second user is 10000, the difference is made to 10000, so that the financial data corresponding to the next period has a trend of falling.
In the embodiment of the invention, in view of the low prediction accuracy of a single data processing model adopted in the existing financial data processing, a plurality of different data processing model sets are adopted to predict the financial data, firstly, the financial data of markets and enterprises and the financial data of users are obtained, the financial data of the markets and the enterprises are preprocessed and then matched with the financial data to obtain a plurality of contemporaneous financial data, then univariate analysis is carried out to obtain average financial data, and the connection among the markets, the enterprises and investors can be found by processing and analyzing a large amount of comprehensive data; and inputting the average financial data and the financial data into a preset financial data processing model set to respectively predict the financial data to obtain the distribution weight and the financial predicted value of each data processing model, and normalizing the financial predicted value to obtain new financial data. The invention adopts a model set integrated by a plurality of data processing models to predict the financial data, integrates the advantages of the plurality of data processing models and can lead the predicted value to be closer to the true value; and finally, determining the change trend of the financial data corresponding to the next period according to the difference value of the two financial data. According to the method, the financial data is predicted through the model set formed by the plurality of data processing models, and the accuracy of prediction is improved.
Referring to fig. 2, a second embodiment of the financial data processing method according to the embodiment of the present invention includes:
201. obtaining market financial data samples, enterprise financial data samples and user financial data samples corresponding to a specified period in a time series format;
202. preprocessing the market financial data sample and the enterprise financial data sample to obtain a plurality of second financial index data;
in this embodiment, the preprocessing includes data difference, synchronization amplification comparison, and previous-period amplification comparison, where the data difference is a difference between the daily stock price and the previous-period stock price; the synchronous amplification comparison is that the daily stock price ratio is increased in the same period of the last year; the last-stage amplification comparison is that the daily stock price ratio is amplified last stage, and a plurality of second financial index data are obtained after the processing
203. Performing contemporaneous data matching on the second financial index data and the user financial data sample to obtain a plurality of second contemporaneous financial data, and performing univariate analysis on the second contemporaneous financial data to obtain second average financial data;
204. respectively inputting the second average financial data and the user financial data samples into a plurality of preset data processing training models to predict financial data, and obtaining a second financial predicted value output by each data processing training model and the goodness of fit of each data processing training model;
in this embodiment, the data processing training model includes an input layer, an activation function, and an output layer, and performs calculation of a next-stage financial value according to the activation function in each data processing model, respectively, to obtain a financial prediction value and a goodness-of-fit of each data processing training model, where the goodness-of-fit represents a fitting effect index of each predictive training model.
205. According to the second financial predicted value of each data processing training model, performing parameter optimization on each data processing training model until each data processing training model converges to obtain a plurality of data processing models;
optionally, in an embodiment, the performing parameter tuning on each data processing training model according to the second financial predicted value of each data processing training model until each data processing training model converges to obtain a plurality of data processing models includes:
calling a preset loss function, and respectively calculating the error rate of the second financial predicted value of each data processing training model;
and according to the error rate, performing fitting parameter optimization on the data processing training models respectively until the data processing training models converge to obtain a plurality of data processing models.
In this embodiment, the loss function is MSE, the error rate is obtained by calculating the mean variance between the predicted value and the true value, the error rate is obtained according to the loss function, the data processing model is continuously trained iteratively until the model converges, so that the error rate is smaller than a preset error threshold, and a plurality of data processing models are obtained.
206. Performing weighted Stacking integration on the plurality of data processing models according to the goodness of fit of each data processing training model to obtain a financial data processing model set comprising a plurality of data processing models;
in this embodiment, the Stacking integration algorithm first trains the primary learner from the initial training set, and then generates a new data set for training the secondary learner. In this new data set, the output of the primary learner is treated as a sample input feature, while the label of the initial sample is still treated as a sample label.
207. Acquiring market financial data and enterprise financial data in a time series format and first user financial data corresponding to the current period;
208. preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
209. performing synchronous data matching on the first financial index data and the first user financial data to obtain a plurality of first synchronous financial data, and performing univariate analysis on the first synchronous financial data to obtain first average financial data;
210. inputting the first average financial data and the first user financial data into a preset financial data processing model set to respectively predict financial data, so as to obtain distribution weights corresponding to the data processing models in the financial data processing model set and first financial predicted values output by the data processing models;
211. according to the distribution weight, performing normalization processing on the first financial predicted value output by each data processing model to obtain second user financial data corresponding to the next period;
212. and determining the user financial data change trend corresponding to the next period according to the difference value of the first user financial data and the second user financial data.
In the embodiment of the invention, the financial investment data prediction model set is formed by integrating a plurality of deep learning models, so that the financial investment data prediction model set integrates the advantages of a plurality of models, and the integrated models respectively output predicted values through the plurality of models, so that the predicted values are closer to real data, and the model has higher reliability compared with only one output value of a single model.
With reference to fig. 3, the financial data processing apparatus according to the embodiment of the present invention is described above, and the financial data processing apparatus according to the embodiment of the present invention includes:
the data acquisition module 301 is configured to acquire market financial data and enterprise financial data in a time series format and first user financial data corresponding to a current period;
a preprocessing module 302, configured to preprocess the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
a matching analysis module 303, configured to perform synchronization data matching on each first financial index data and the first user financial data to obtain a plurality of first synchronization financial data, and perform univariate analysis on each first synchronization financial data to obtain first average financial data;
the data processing module 304 is configured to input the first average financial data and the first user financial data into a preset financial data processing model set to perform financial data prediction, so as to obtain a distribution weight corresponding to each data processing model in the financial data processing model set and a first financial prediction value output by each data processing model;
a normalization module 305, configured to perform normalization processing on the first financial predicted values output by the data processing models according to the distribution weights, so as to obtain second user financial data corresponding to a next period;
and the trend determining module 306 is configured to determine a user financial data change trend corresponding to the next period according to a difference between the first user financial data and the second user financial data.
Referring to fig. 4, a second embodiment of the financial data processing apparatus according to the present invention includes:
the data acquisition module 301 is configured to acquire market financial data and enterprise financial data in a time series format and first user financial data corresponding to a current period;
a preprocessing module 302, configured to preprocess the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
a matching analysis module 303, configured to perform synchronization data matching on each first financial index data and the first user financial data to obtain a plurality of first synchronization financial data, and perform univariate analysis on each first synchronization financial data to obtain first average financial data;
the data processing module 304 is configured to input the first average financial data and the first user financial data into a preset financial data processing model set to perform financial data prediction, so as to obtain a distribution weight corresponding to each data processing model in the financial data processing model set and a first financial prediction value output by each data processing model;
a normalization module 305, configured to perform normalization processing on the first financial predicted values output by the data processing models according to the distribution weights, so as to obtain second user financial data corresponding to a next period;
and the trend determining module 306 is configured to determine a user financial data change trend corresponding to the next period according to a difference between the first user financial data and the second user financial data.
Optionally, in an embodiment, the financial data processing apparatus further includes:
the sample processing module 307 is configured to obtain market financial data samples, enterprise financial data samples, and user financial data samples corresponding to a specified period in a time series format; preprocessing the market financial data sample and the enterprise financial data sample to obtain a plurality of second financial index data; performing contemporaneous data matching on the second financial index data and the user financial data sample to obtain a plurality of second contemporaneous financial data, and performing univariate analysis on the second contemporaneous financial data to obtain second average financial data;
the sample prediction module 308 is configured to input the second average financial data and the user financial data samples into a plurality of preset data processing training models to perform financial data prediction, so as to obtain a second financial prediction value output by each data processing training model and a goodness of fit of each data processing training model;
the model optimization module 309 is configured to perform parameter tuning on each data processing training model according to the second financial prediction value of each data processing training model until each data processing training model converges to obtain a plurality of data processing models;
and the model integration module 310 is configured to perform weighted Stacking integration on the plurality of data processing models according to the goodness of fit of each data processing training model to obtain a financial data processing model set including the plurality of data processing models.
Optionally, in an embodiment, the model optimization module 309 is specifically configured to:
calling a preset loss function, and respectively calculating the error rate of the second financial predicted value of each data processing model;
and according to the error rate, performing fitting parameter optimization on the data processing training models respectively until the data processing training models converge to obtain a plurality of data processing models.
Optionally, in an embodiment, the preprocessing module 302 is specifically configured to:
according to the market financial data and the enterprise financial data, carrying out data difference on the market financial data and the enterprise financial data to obtain a plurality of difference indexes;
carrying out synchronous amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of synchronous amplification indexes;
performing the up-date amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of up-date amplification indexes;
wherein the first financial index data includes the difference index, the contemporaneous amplification index, and the up-dated amplification index.
Optionally, in an embodiment, the matching analysis module 303 is specifically configured to:
time sequence alignment is carried out on the first financial index data and the first user financial data, and data corresponding to the same time are respectively taken for matching to obtain a plurality of first synchronous financial data;
calculating the average value of each first synchronous financial data in the corresponding period, and generating a univariate analysis chart corresponding to each first synchronous financial data according to the average value;
and performing characteristic screening on the univariate analysis chart to obtain first average financial data.
Optionally, in an embodiment, the data prediction module 304 is specifically configured to:
inputting the first average financial data and the first user financial data into a preset financial data processing model set, wherein the financial data processing model set comprises an Xgboost model, a GBRT model, an Adaboost model, a DNN model and an LSTM model;
and respectively carrying out weight operation and next-period financial value operation through the Xgboost model, the GBRT model, the Adaboost model, the DNN model and the LSTM model to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model.
Optionally, in an embodiment, the normalization module 305 is specifically configured to:
calculating a weighted financial predicted value of the first financial predicted values output by the data processing models according to the distribution weight;
and calling a preset normalization function, and performing normalization processing on the weighted financial predicted value to obtain second user financial data corresponding to the next period.
In the embodiment of the invention, in view of the low prediction accuracy of a single data processing model adopted in the existing financial data processing, a plurality of different data processing model sets are adopted to predict the financial data, firstly, the financial data of markets and enterprises and the financial data of users are obtained, the financial data of the markets and the enterprises are preprocessed and then matched with the financial data to obtain a plurality of contemporaneous financial data, then univariate analysis is carried out to obtain average financial data, and the connection among the markets, the enterprises and investors can be found by processing and analyzing a large amount of comprehensive data; and inputting the average financial data and the financial data into a preset financial data processing model set to respectively predict the financial data to obtain the distribution weight and the financial predicted value of each data processing model, and normalizing the financial predicted value to obtain new financial data. The invention adopts a model set integrated by a plurality of data processing models to predict the financial data, integrates the advantages of the plurality of data processing models and can lead the predicted value to be closer to the true value; and finally, determining the change trend of the financial data corresponding to the next period according to the difference value of the two financial data. According to the method, the financial data is predicted through the model set formed by the plurality of data processing models, and the accuracy of prediction is improved.
The financial data processing device in the embodiment of the present invention is described in detail in the above fig. 3 and fig. 4 from the perspective of the modular functional entity, and the financial data processing device in the embodiment of the present invention is described in detail in the following from the perspective of hardware processing.
Fig. 5 is a schematic structural diagram of a financial data processing apparatus 500 according to an embodiment of the present invention, where the financial data processing apparatus 500 may have a relatively large difference due to different configurations or performances, and may include one or more processors (CPUs) 510 (e.g., one or more processors) and a memory 520, and one or more storage media 530 (e.g., one or more mass storage devices) storing applications 533 or data 532. Memory 520 and storage media 530 may be, among other things, transient or persistent storage. The program stored in the storage medium 530 may include one or more modules (not shown), each of which may include a series of instruction operations for the financial data processing apparatus 500. Further, the processor 510 may be configured to communicate with the storage medium 530 to execute a series of instruction operations in the storage medium 530 on the financial data processing apparatus 500.
The financial data processing apparatus 500 may also include one or more power supplies 540, one or more wired or wireless network interfaces 550, one or more input-output interfaces 560, and/or one or more operating systems 531, such as Windows Server, Mac OS X, Unix, Linux, FreeBSD, and the like. Those skilled in the art will appreciate that the financial data processing apparatus configuration shown in FIG. 5 does not constitute a limitation of the financial data processing apparatus and may include more or fewer components than shown, or some components may be combined, or a different arrangement of components.
The present invention also provides a financial data processing apparatus comprising a memory and a processor, the memory having stored therein computer readable instructions which, when executed by the processor, cause the processor to perform the steps of the financial data processing method in the above embodiments.
The present invention also provides a computer-readable storage medium, which may be a non-volatile computer-readable storage medium, and which may also be a volatile computer-readable storage medium, having stored therein instructions, which, when executed on a computer, cause the computer to perform the steps of the financial data processing method.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a read-only memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (10)

1. A financial data processing method, characterized in that the financial data processing method comprises:
acquiring market financial data and enterprise financial data in a time series format and first user financial data corresponding to the current period;
preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
performing synchronous data matching on the first financial index data and the first investment financial data to obtain a plurality of first synchronous financial data, and performing univariate analysis on the first synchronous financial data to obtain first average financial data;
inputting the first average financial data and the first user financial data into a preset financial data processing model set to respectively predict financial data, so as to obtain distribution weights corresponding to the data processing models in the financial data processing model set and first financial predicted values output by the data processing models;
according to the distribution weight, performing normalization processing on the first financial predicted value output by each data processing model to obtain second user financial data corresponding to the next period;
and determining the user financial data change trend corresponding to the next period according to the difference value of the first user financial data and the second user financial data.
2. The method of claim 1, wherein prior to said obtaining market financial data, business financial data, and first user financial data corresponding to a current period in a time series format, further comprising:
obtaining market financial data samples, enterprise financial data samples and user financial data samples corresponding to a specified period in a time series format;
preprocessing the market financial data sample and the enterprise financial data sample to obtain a plurality of second financial index data;
performing contemporaneous data matching on the second financial index data and the user financial data sample to obtain a plurality of second contemporaneous financial data, and performing univariate analysis on the second contemporaneous financial data to obtain second average financial data;
respectively inputting the second average financial data and the user financial data samples into a plurality of preset data processing training models to predict financial data, and obtaining a second financial predicted value output by each data processing training model and the goodness of fit of each data processing training model;
according to the second financial predicted value of each data processing training model, performing parameter optimization on each data processing training model until each data processing training model converges to obtain a plurality of data processing models;
and performing weighted Stacking integration on the plurality of data processing models according to the goodness of fit of each data processing training model to obtain a financial data processing model set comprising a plurality of data processing models.
3. The method of claim 2, wherein the performing parameter tuning on each data processing training model according to the second financial prediction value of each data processing training model until each data processing training model converges to obtain a plurality of data processing models comprises:
calling a preset loss function, and respectively calculating the error rate of the second financial predicted value of each data processing model;
and according to the error rate, performing fitting parameter optimization on the data processing training models respectively until the data processing training models converge to obtain a plurality of data processing models.
4. The method of claim 1, wherein the preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data comprises:
according to the market financial data and the enterprise financial data, carrying out data difference on the market financial data and the enterprise financial data to obtain a plurality of difference indexes;
carrying out synchronous amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of synchronous amplification indexes;
performing the up-date amplification comparison on the market financial data and the enterprise financial data to obtain a plurality of up-date amplification indexes;
wherein the first financial index data includes the difference index, the contemporaneous amplification index, and the up-dated amplification index.
5. The method as claimed in claim 1 or 4, wherein the matching of the contemporaneous data of the first financial index data and the first user financial data to obtain a plurality of first contemporaneous financial data, and the performing univariate analysis of the first contemporaneous financial data to obtain the first average financial data comprises:
time sequence alignment is carried out on the first financial index data and the first user financial data, and data corresponding to the same time are respectively taken for matching to obtain a plurality of first synchronous financial data;
calculating the average value of each first synchronous financial data in the corresponding investment period, and generating a univariate analysis chart corresponding to each first synchronous financial data according to the average value;
and performing characteristic screening on the univariate analysis chart to obtain first average financial data.
6. The method of claim 5, wherein the step of inputting the first average financial data and the first user financial data into a preset financial data processing model set for financial data prediction to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model comprises:
inputting the first average financial data and the first user financial data into a preset financial data processing model set, wherein the financial data processing model set comprises an Xgboost model, a GBRT model, an Adaboost model, a DNN model and an LSTM model;
and respectively carrying out weight operation and next-period financial value operation through the Xgboost model, the GBRT model, the Adaboost model, the DNN model and the LSTM model to obtain the distribution weight corresponding to each data processing model in the financial data processing model set and the first financial predicted value output by each data processing model.
7. The financial data processing method of claim 6, wherein the normalizing the first financial prediction values output by the data processing models according to the distribution weight to obtain second user financial data corresponding to a next period comprises:
calculating a weighted financial predicted value of the first financial predicted values output by the data processing models according to the distribution weight;
and calling a preset normalization function, and performing normalization processing on the weighted financial predicted value to obtain second user financial data corresponding to the next period.
8. A financial data processing apparatus, characterized in that the financial data processing apparatus comprises:
the data acquisition module is used for acquiring market financial data, enterprise financial data and first user financial data corresponding to the current period in a time series format;
the preprocessing module is used for preprocessing the market financial data and the enterprise financial data to obtain a plurality of first financial index data;
the matching analysis module is used for carrying out synchronous data matching on the first financial index data and the first user financial data to obtain a plurality of first synchronous financial data, and carrying out univariate analysis on the first synchronous financial data to obtain first average financial data;
the data prediction module is used for inputting the first average financial data and the first user financial data into a preset financial data processing model set to respectively perform financial data prediction to obtain distribution weights corresponding to the data processing models in the financial data processing model set and first financial prediction values output by the data processing models;
the normalization module is used for performing normalization processing on the first financial predicted values output by the data processing models according to the distribution weights to obtain second user financial data corresponding to the next period;
and the behavior judgment module is used for determining the user financial data change trend corresponding to the next period according to the difference value of the first user financial data and the second user financial data.
9. A financial data processing apparatus, characterized in that the financial data processing apparatus comprises: a memory and at least one processor, the memory having instructions stored therein;
the at least one processor invokes the instructions in the memory to cause the financial data processing apparatus to perform the financial data processing method of any one of claims 1-7.
10. A computer-readable storage medium having instructions stored thereon, wherein the instructions, when executed by a processor, implement the financial data processing method of any one of claims 1-7.
CN202011635804.0A 2020-12-31 2020-12-31 Financial data processing method, device, equipment and storage medium Pending CN112732786A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202011635804.0A CN112732786A (en) 2020-12-31 2020-12-31 Financial data processing method, device, equipment and storage medium
PCT/CN2021/084256 WO2022141877A1 (en) 2020-12-31 2021-03-31 Financial data processing method, apparatus and device, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011635804.0A CN112732786A (en) 2020-12-31 2020-12-31 Financial data processing method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN112732786A true CN112732786A (en) 2021-04-30

Family

ID=75608625

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011635804.0A Pending CN112732786A (en) 2020-12-31 2020-12-31 Financial data processing method, device, equipment and storage medium

Country Status (2)

Country Link
CN (1) CN112732786A (en)
WO (1) WO2022141877A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112991071A (en) * 2021-04-28 2021-06-18 南京玄德毅信息技术有限公司 Financial product market promotion strategy optimization system and method based on big data
CN113781233A (en) * 2021-07-29 2021-12-10 河北洋绣球网络科技有限公司 Financial data service analysis system based on big data

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116934486B (en) * 2023-09-15 2024-01-12 深圳市蓝宇飞扬科技有限公司 Decision evaluation method and system based on deep learning

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11354747B2 (en) * 2016-04-16 2022-06-07 Overbond Ltd. Real-time predictive analytics engine
CN107274007A (en) * 2017-05-25 2017-10-20 上海拜富网络科技股份有限公司 Finance data Forecasting Methodology based on artificial neural network
CN107977864A (en) * 2017-12-07 2018-05-01 北京贝塔智投科技有限公司 A kind of customer insight method and system suitable for financial scenario
CN110264013A (en) * 2019-06-27 2019-09-20 苏州派维斯信息科技有限公司 Financial prediction method and system
CN111192144A (en) * 2020-01-03 2020-05-22 湖南工商大学 Financial data prediction method, device, equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112991071A (en) * 2021-04-28 2021-06-18 南京玄德毅信息技术有限公司 Financial product market promotion strategy optimization system and method based on big data
CN113781233A (en) * 2021-07-29 2021-12-10 河北洋绣球网络科技有限公司 Financial data service analysis system based on big data

Also Published As

Publication number Publication date
WO2022141877A1 (en) 2022-07-07

Similar Documents

Publication Publication Date Title
Henrique et al. Literature review: Machine learning techniques applied to financial market prediction
CN112732786A (en) Financial data processing method, device, equipment and storage medium
Delen et al. Measuring firm performance using financial ratios: A decision tree approach
Zhao Futures price prediction of agricultural products based on machine learning
CN107766929B (en) Model analysis method and device
Shah et al. A comprehensive review on multiple hybrid deep learning approaches for stock prediction
CN110738564A (en) Post-loan risk assessment method and device and storage medium
CN110930038A (en) Loan demand identification method, loan demand identification device, loan demand identification terminal and loan demand identification storage medium
Liu et al. Stock price prediction model based on RBF-SVM algorithm
CN109815480B (en) Data processing method and device and storage medium
CN110689437A (en) Communication construction project financial risk prediction method based on random forest
Wimmer et al. Leveraging vision-language models for granular market change prediction
CN113506173A (en) Credit risk assessment method and related equipment thereof
CN117196808A (en) Mobility risk prediction method and related device for peer business
CN112163731A (en) Special transformer user electric charge recovery risk identification method based on weighted random forest
CN110866829A (en) Stock price prediction method based on integrated learning model
CN115936184A (en) Load prediction matching method suitable for multi-user types
Agusta et al. Technical analysis based automatic trading prediction system for stock exchange using support vector machine
Zhang et al. Multi-factor stock selection model based on kernel support vector machine
CN110458383B (en) Method and device for realizing demand processing servitization, computer equipment and storage medium
CN113762415A (en) Neural network-based intelligent matching method and system for automobile financial products
CN114282875A (en) Flow approval certainty rule and semantic self-learning combined judgment method and device
CN111340632A (en) Resource control method and device
Deng et al. Automatic digital modulation classification using instantaneous features
Wu et al. A study of patent analysis for stock price prediction

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination