text_plain_output_1.png image_output_1.png
from sklearn.linear_model import LinearRegression

import pandas as pd

df = pd.read_csv('../input/body-fat-prediction-dataset/bodyfat.csv')

df = df.drop(columns=['Neck', 'Chest', 'Hip'])

X = df[['BodyFat', 'Age']]
y = df['Density']

model = LinearRegression()
model.fit(X, y)