Haciendo un ejercicio de validacion externa con cross validation y split, con el siguiente código
'import pandas as pd
from sklearn.model_selection import train_test_split
from sklearn import linear_model
from sklearn.metrics import r2_score
data = pd.read_csv('C:/Users/DELL/Desktop/base_datos_2008.csv')
df = data.dropna(subset = ['ArrDelay'])
df = df.sample(frac=1).head(1000)
X = df[['AirTime', 'Distance', 'DepDelay']]
Y = df['ArrDelay']
X_train, X_test, y_train, y_test = train_test_split("X,Y", test_size = .2, random_state = 2)
regrINTERNA = linear_model.LinearRegression()
regrINTERNA.fit(X, Y)
prediccionesINTERNA = regrINTERNA.predict(X)
print("R2: ", r2_score(Y, prediccionesINTERNA))'
Teniendo el siguiente resultado:
'X_train, X_test, y_train, y_test = train_test_split("X,Y", test_size = .2, random_state = 2)
ValueError: not enough values to unpack (expected 4, got 2)'
No se cual ea el erro tengo python 3.8.3 de 64 bits.