Question: i need a python code to cluster the animals in this table , first we need to transform non numeric features to numeric ones (
i need a python code to cluster the animals in this table first we need to transform non numeric features to numeric ones use other method than one hot encoding standardize the data plot the elbow graph and make sure that it looks like an elbow please and find the optimal number of clusters, print the clusters output the animals contained in and label the clusters, the clusters must realistic as much as possible foe example you can't put a sheep and a cheetah in the same cluster.
and the kmeans algorith can't be imported from sklearn library it has to be written as a function within the code.
Given a table of animals and these information about them: Weight kgTop Speed kmhLifespan years Social Behavior, Diet and Habitat. assume you are part of an organizing team to design a large openrange Zoo for the animals.The zoo consists of sections; each section includes a group ie cluster of animals. These sections will feature
expansive openair houses, catering to either a single species or multiple species. The zoo could include multiple water bodies, wooded areas etc.The ultimate goal is to craft a zoo that appropriate for the animals' physical and mental wellbeing while
simultaneously attractive to our visitors.
Your tasks are:
Cluster the animals into groups to assist in designing the Park.
Label each cluster with proper name ielarge funny animals
To achieve this, write a python program to find the optimum clustering for the animals listed in the
table. The python program performs the following tasks:
o Read animal from the Table Use Panda library Write a function for Kmeans algorithm.
o Apply Kmeans algorithm repeatedly with different Ks
o Plot the elbow graph. Find optimum clustering. Give meaningful labels to the clusters.tableAnimal,Weight kgtableTop Speed
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
