Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

The Scikit-learn library has a number of built-in datasets. In this exercise, we will use the Diabetes dataset. First, you have to import the datasets

The Scikit-learn library has a number of built-in datasets. In this exercise, we will use the Diabetes dataset. First, you have to import the datasets module of the scikit-learn library and then you call the load_diabetes() function to load the dataset into a variable that we name as diabetes. This dataset contains physiological data of 442 patients and as corresponding target an indicator of the disease progression after a year. The physiological data occupies the first 10 columns respectively: Age Sex Body Mass Index Blood Pressure S1, S2, S3, S4, S5, S6 (six blood serum measurements) These measurements can be obtained by calling the data attribute. For example, we look at the 10 values for the first patient. As for the indicators of the progress of the disease, that is, the values that must correspond to the results of your predictions, these are obtainable by means of the target attribute

Partition the 442 patients into a training set (composed of the first 422 patients) and a test set (the last 20 patients).

Once the model is trained (lets say using sklearn), get the ten coefficients calculated for each physiological variable, using the coef_ attribute of the predictive model

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions

Question

=+j Understand different types of regions in the world.

Answered: 1 week ago