Order Book Data Conversion to 2D Tensor for CNN Stock Prediction

Resolve Bottlenecks,
Find Innovative Solutions
Generate Solutions

Solution Overview

Problem

Machine learning models, particularly those specialized in pattern recognition like CNNs, face challenges in processing order book data stored in table form, leading to loss of important information and deteriorated prediction performance for stock price prediction.

Innovation Solution

A method to convert order book data into 2D data in tensor form with a time axis and price axis in units of tick, including mid prices, allowing separate channels for bid and ask prices, which is then normalized and input into a machine learning model for improved prediction.

Engineering Contradictions & Design Principles

VSEngineering Contradiction Analysis

1Adaptability or versatility

If order book data is converted into 2D data for machine learning models, then the data becomes suitable for CNN processing, but important information for stock price prediction can be lost

Engineering Contradiction:
Improvecompatibility with CNN modelsVSAvoidloss of important information
Core Design Contradiction:
Adaptability or versatilityVSLoss of information

Solution Approach 1:

The patent transforms order book data from a tabular format to a 2D tensor format with dimensions representing time and price levels. This dimensional transformation enables the data to be processed by CNN models while preserving critical information through careful construction of the 2D structure that maintains temporal and price-level relationships.

Inventive Principle:
Principle #17Another dimension (Dimensionality change)

Solution Approach 2:

The patent segments the order book data into multiple channels, where each channel corresponds to different price levels or time intervals. This segmentation allows the model to process and analyze specific portions of the data independently while maintaining the overall structure and relationships necessary for accurate stock price prediction.

Inventive Principle:
Principle #1Segmentation

2Productivity

If order book data is converted into 2D data, then pattern recognition can be performed, but prediction performance deteriorates due to information loss

Engineering Contradiction:
Improvepattern recognition capabilityVSAvoidprediction performance
Core Design Contradiction:
ProductivityVSReliability

Solution Approach 1:

The patent applies parameter changes by normalizing the 2D data and adjusting the resolution and scaling of time and price dimensions. These parameter transformations optimize the data for both pattern recognition by CNN models and maintain the predictive accuracy needed for reliable stock price forecasting.

Inventive Principle:
Principle #35Parameter changes

Data Source

PatentUS20240153003A1Method and system for converting order book data into 2d data for machine learning models
Publication Date: 2024.05.09 REBELLIONS INC
  • US20240153003A1 patent drawing
  • US20240153003A1 patent drawing
  • US20240153003A1 patent drawing

AI summary

Provided is a method for converting order book data into 2D data for a machine learning model, which is performed by one or more processors, in which the method includes acquiring order book data including data items for a plurality of bid prices and data items for a plurality of ask prices for a stock traded in a first stock exchange according to time from a time point in the past that is a predetermined period of time earlier, to a current time point, calculating a mid price based on a highest bid price of the plurality of bid prices and a lowest ask price of the plurality of ask prices, and generating data in tensor form having a first axis of times at certain time intervals and a second axis of prices in units of tick.