|
1573 | 1573 | "output_type": "stream",
|
1574 | 1574 | "text": [
|
1575 | 1575 | "Average age for customers in cluster one: 40.94444444444444\n",
|
1576 |
| - "Average annual income (in thousends) for customers in cluster one: 104.88888888888889\n", |
1577 |
| - "Deviation of the mean for annual income (in thousends) for customers in cluster one: 16.927587243211693\n", |
| 1576 | + "Average annual income (in thousands) for customers in cluster one: 104.88888888888889\n", |
| 1577 | + "Deviation of the mean for annual income (in thousands) for customers in cluster one: 16.927587243211693\n", |
1578 | 1578 | "In cluster one we have: 18 customers\n",
|
1579 | 1579 | "From those customers we have 9 male and 9 female\n"
|
1580 | 1580 | ]
|
1581 | 1581 | }
|
1582 | 1582 | ],
|
1583 | 1583 | "source": [
|
1584 | 1584 | "print(\"Average age for customers in cluster one: {}\".format(np.array(cluster_2['Age']).mean()))\n",
|
1585 |
| - "print(\"Average annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_2['Annual Income (k$)']).mean()))\n", |
1586 |
| - "print(\"Deviation of the mean for annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_2['Annual Income (k$)']).std()))\n", |
| 1585 | + "print(\"Average annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_2['Annual Income (k$)']).mean()))\n", |
| 1586 | + "print(\"Deviation of the mean for annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_2['Annual Income (k$)']).std()))\n", |
1587 | 1587 | "print(\"In cluster one we have: {} customers\".format(cluster_2.shape[0]))\n",
|
1588 | 1588 | "print(\"From those customers we have {} male and {} female\".format(cluster_2.loc[(cluster_2['Genre'] == 1.0)].shape[0], cluster_2.loc[(cluster_2['Genre'] == 0.0)].shape[0]))"
|
1589 | 1589 | ]
|
|
2137 | 2137 | "output_type": "stream",
|
2138 | 2138 | "text": [
|
2139 | 2139 | "Average age for customers in cluster one: 48.53333333333333\n",
|
2140 |
| - "Average annual income (in thousends) for customers in cluster one: 52.68888888888889\n", |
2141 |
| - "Deviation of the mean for annual income (in thousends) for customers in cluster one: 18.271194356414593\n", |
| 2140 | + "Average annual income (in thousands) for customers in cluster one: 52.68888888888889\n", |
| 2141 | + "Deviation of the mean for annual income (in thousands) for customers in cluster one: 18.271194356414593\n", |
2142 | 2142 | "In cluster one we have: 90 customers\n",
|
2143 | 2143 | "From those customers we have 40 male and 50 female\n"
|
2144 | 2144 | ]
|
2145 | 2145 | }
|
2146 | 2146 | ],
|
2147 | 2147 | "source": [
|
2148 | 2148 | "print(\"Average age for customers in cluster one: {}\".format(np.array(cluster_3['Age']).mean()))\n",
|
2149 |
| - "print(\"Average annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_3['Annual Income (k$)']).mean()))\n", |
2150 |
| - "print(\"Deviation of the mean for annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_3['Annual Income (k$)']).std()))\n", |
| 2149 | + "print(\"Average annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_3['Annual Income (k$)']).mean()))\n", |
| 2150 | + "print(\"Deviation of the mean for annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_3['Annual Income (k$)']).std()))\n", |
2151 | 2151 | "print(\"In cluster one we have: {} customers\".format(cluster_3.shape[0]))\n",
|
2152 | 2152 | "print(\"From those customers we have {} male and {} female\".format(cluster_3.loc[(cluster_3['Genre'] == 1.0)].shape[0], cluster_3.loc[(cluster_3['Genre'] == 0.0)].shape[0]))"
|
2153 | 2153 | ]
|
|
2442 | 2442 | "output_type": "stream",
|
2443 | 2443 | "text": [
|
2444 | 2444 | "Average age for customers in cluster one: 32.58620689655172\n",
|
2445 |
| - "Average annual income (in thousends) for customers in cluster one: 86.75862068965517\n", |
2446 |
| - "Deviation of the mean for annual income (in thousends) for customers in cluster one: 12.62907202317211\n", |
| 2445 | + "Average annual income (in thousands) for customers in cluster one: 86.75862068965517\n", |
| 2446 | + "Deviation of the mean for annual income (in thousands) for customers in cluster one: 12.62907202317211\n", |
2447 | 2447 | "In cluster one we have: 29 customers\n",
|
2448 | 2448 | "From those customers we have 12 male and 17 female\n"
|
2449 | 2449 | ]
|
2450 | 2450 | }
|
2451 | 2451 | ],
|
2452 | 2452 | "source": [
|
2453 | 2453 | "print(\"Average age for customers in cluster one: {}\".format(np.array(cluster_4['Age']).mean()))\n",
|
2454 |
| - "print(\"Average annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_4['Annual Income (k$)']).mean()))\n", |
2455 |
| - "print(\"Deviation of the mean for annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_4['Annual Income (k$)']).std()))\n", |
| 2454 | + "print(\"Average annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_4['Annual Income (k$)']).mean()))\n", |
| 2455 | + "print(\"Deviation of the mean for annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_4['Annual Income (k$)']).std()))\n", |
2456 | 2456 | "print(\"In cluster one we have: {} customers\".format(cluster_4.shape[0]))\n",
|
2457 | 2457 | "print(\"From those customers we have {} male and {} female\".format(cluster_4.loc[(cluster_4['Genre'] == 1.0)].shape[0], cluster_4.loc[(cluster_4['Genre'] == 0.0)].shape[0]))"
|
2458 | 2458 | ]
|
|
2803 | 2803 | "output_type": "stream",
|
2804 | 2804 | "text": [
|
2805 | 2805 | "Average age for customers in cluster one: 28.416666666666668\n",
|
2806 |
| - "Average annual income (in thousends) for customers in cluster one: 62.416666666666664\n", |
2807 |
| - "Deviation of the mean for annual income (in thousends) for customers in cluster one: 9.67923034130297\n", |
| 2806 | + "Average annual income (in thousands) for customers in cluster one: 62.416666666666664\n", |
| 2807 | + "Deviation of the mean for annual income (in thousands) for customers in cluster one: 9.67923034130297\n", |
2808 | 2808 | "In cluster one we have: 36 customers\n",
|
2809 | 2809 | "From those customers we have 16 male and 20 female\n"
|
2810 | 2810 | ]
|
2811 | 2811 | }
|
2812 | 2812 | ],
|
2813 | 2813 | "source": [
|
2814 | 2814 | "print(\"Average age for customers in cluster one: {}\".format(np.array(cluster_5['Age']).mean()))\n",
|
2815 |
| - "print(\"Average annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_5['Annual Income (k$)']).mean()))\n", |
2816 |
| - "print(\"Deviation of the mean for annual income (in thousends) for customers in cluster one: {}\".format(np.array(cluster_5['Annual Income (k$)']).std()))\n", |
| 2815 | + "print(\"Average annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_5['Annual Income (k$)']).mean()))\n", |
| 2816 | + "print(\"Deviation of the mean for annual income (in thousands) for customers in cluster one: {}\".format(np.array(cluster_5['Annual Income (k$)']).std()))\n", |
2817 | 2817 | "print(\"In cluster one we have: {} customers\".format(cluster_5.shape[0]))\n",
|
2818 | 2818 | "print(\"From those customers we have {} male and {} female\".format(cluster_5.loc[(cluster_5['Genre'] == 1.0)].shape[0], cluster_5.loc[(cluster_5['Genre'] == 0.0)].shape[0]))"
|
2819 | 2819 | ]
|
|
0 commit comments