## With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

No credit card required

# Computing mean values for all of the variables

Interesting comparisons can be made, purely using SQL, by calculating the coefficient of variation for all of the variables, and grouping by outcome. A coefficient of variation is a way in which we can standardize the means and variances of the variables and thus be able to disregard scale when making comparisons:

```%sql select outcome,        mean(pregnant)/std(pregnant),        mean(glucose)/std(glucose),        mean(pressure)/std(pressure),        mean(triceps)/std(triceps),        mean(insulin)/std(insulin),        mean(mass)/std(mass),        mean(pedigree)/std(pedigree),        mean(age)/std(age) from out_tbl group by 1
```
1. After the query is done, switch to the plot window, and change the plot type to line chart.

2. Then drag the outcome ...

## With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

No credit card required