For this chapter, let's pretend you secured a predictive analytics assignment with a cardiology practice located in the United States. The practice wants you to predict which patients are at risk of dying within 6 months of their visit to the clinic. They make their data available to you in the form of a database that includes six tables. For simplicity, we truncate the database to include the information for five patients only. Our task is to manipulate the data using the SQL language to consolidate it into a single table so that it can be used for machine learning. We will first go over the patients in the database and the database structure. Then, we will introduce basic SQL concepts for engineering and manipulate the data into a form amenable to machine learning.
United States
Great Britain
India
Germany
France
Canada
Russia
Spain
Brazil
Australia
Singapore
Hungary
Ukraine
Luxembourg
Estonia
Lithuania
South Korea
Turkey
Switzerland
Colombia
Taiwan
Chile
Norway
Ecuador
Indonesia
New Zealand
Cyprus
Denmark
Finland
Poland
Malta
Czechia
Austria
Sweden
Italy
Egypt
Belgium
Portugal
Slovenia
Ireland
Romania
Greece
Argentina
Netherlands
Bulgaria
Latvia
South Africa
Malaysia
Japan
Slovakia
Philippines
Mexico
Thailand