Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Challenge | Building and Training Model
Explore the Linear Regression Using Python
course content

Зміст курсу

Explore the Linear Regression Using Python

Explore the Linear Regression Using Python

1. What is the Linear Regression?
2. Correlation
3. Building and Training Model
4. Metrics to Evaluate the Model
5. Multivariate Linear Regression

bookChallenge

Let’s combine our knowledge!

Завдання

In this task, you build, train and fit your model and make predictions based on it. This time you will make predictions about total_phenols, based on flavanoids. It means that your target now is total_phenols.

Your plan:

  1. [Line #18] Define the target (in this task it's total_phenols).
  2. [Line #25] Split the data 70-30 (70% of the data is for training and 30% is for testing) and insert 1 as a random parameter.
  3. [Line #26] Initialize linear regression model .
  4. [Line #27] Fit the model using your tain data.
  5. [Line #30] Assign np.array() to the variable new_flavanoids if their number is 1 (don't forget to use function .reshape(-1,1)).
  6. [Line #31] Predict and assign the amount of flavanoids to the variable predicted_value.
  7. [Line #32] Print the predicted amount of flavanoids.

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 3. Розділ 4
toggle bottom row

bookChallenge

Let’s combine our knowledge!

Завдання

In this task, you build, train and fit your model and make predictions based on it. This time you will make predictions about total_phenols, based on flavanoids. It means that your target now is total_phenols.

Your plan:

  1. [Line #18] Define the target (in this task it's total_phenols).
  2. [Line #25] Split the data 70-30 (70% of the data is for training and 30% is for testing) and insert 1 as a random parameter.
  3. [Line #26] Initialize linear regression model .
  4. [Line #27] Fit the model using your tain data.
  5. [Line #30] Assign np.array() to the variable new_flavanoids if their number is 1 (don't forget to use function .reshape(-1,1)).
  6. [Line #31] Predict and assign the amount of flavanoids to the variable predicted_value.
  7. [Line #32] Print the predicted amount of flavanoids.

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 3. Розділ 4
toggle bottom row

bookChallenge

Let’s combine our knowledge!

Завдання

In this task, you build, train and fit your model and make predictions based on it. This time you will make predictions about total_phenols, based on flavanoids. It means that your target now is total_phenols.

Your plan:

  1. [Line #18] Define the target (in this task it's total_phenols).
  2. [Line #25] Split the data 70-30 (70% of the data is for training and 30% is for testing) and insert 1 as a random parameter.
  3. [Line #26] Initialize linear regression model .
  4. [Line #27] Fit the model using your tain data.
  5. [Line #30] Assign np.array() to the variable new_flavanoids if their number is 1 (don't forget to use function .reshape(-1,1)).
  6. [Line #31] Predict and assign the amount of flavanoids to the variable predicted_value.
  7. [Line #32] Print the predicted amount of flavanoids.

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Let’s combine our knowledge!

Завдання

In this task, you build, train and fit your model and make predictions based on it. This time you will make predictions about total_phenols, based on flavanoids. It means that your target now is total_phenols.

Your plan:

  1. [Line #18] Define the target (in this task it's total_phenols).
  2. [Line #25] Split the data 70-30 (70% of the data is for training and 30% is for testing) and insert 1 as a random parameter.
  3. [Line #26] Initialize linear regression model .
  4. [Line #27] Fit the model using your tain data.
  5. [Line #30] Assign np.array() to the variable new_flavanoids if their number is 1 (don't forget to use function .reshape(-1,1)).
  6. [Line #31] Predict and assign the amount of flavanoids to the variable predicted_value.
  7. [Line #32] Print the predicted amount of flavanoids.

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Секція 3. Розділ 4
Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
some-alt