Menu

Preparing Features and Target Variable

Preparing Features and Target Variable

Select the engineered features as inputs and the closing price as the target variable.

Code

X = stock_data[
['Open_Close', 'High_Low']
]
Y = stock_data['Close']

Explanation

  • X contains the input features.
  • Y contains the stock closing prices to be predicted.