Kmeans and hierachal clustering in Python (with and without packages)

In short: First, use unsupervised learning techniques to determine Kmeans and hierarchal clustering. Next, use random forest classification to predict cluster numbers and calculate accuracy. Last, write Kmeans clustering from scratch using Python [No packages can be used for this part]. Compare results.

Long version:

First, use dataset1 (CSV) with unsupervised learning techniques. Use Kmeans to determine the # of clusters. Tabulate the # of clusters from 1 – 40 and total within-cluster variance. Plot the scree plot. Using hierarchal clustering, calculate the pairwise distance. Create various dendrograms using complete and average linkage. Cut dendrogram into groups of 5-7. Which is the most appropriate # of groups?

Next, do the same exercise above except this time we use random forest classification.

Last, using dataset2 (CSV), write a function (without using Kmeans related packages) that calculates the within-cluster variance, aggregates the data by the cluster number, and plots “total within-cluster vs. a number of the cluster”. Add the cluster number to the last column of the dataset, predict the cluster number using logistic regression and calculate the accuracy of your model.

Briefly compare results from each method.

Sample Solution

The Australian Institute of Family Studies (AIFS) Child Family and Community Australia (CFCA) (2014) identified that the current approach to child protection in Australia has acknowledged the roles the state and territory governments must play in protecting all children from abuse and neglect. It also explained that governments had assumed their obligation in meeting the essential developmental needs of all children, particularly those children whose parents cannot or do not provide a safe, protective environment or whose parents are responsible for the abuse or neglect these children experienced.
The Community and Disability Services Ministerial Advisory Committee (CDSMAC) developed the National Framework for Protecting Australia’s Children 2009’2020 (COAG 2009) which included a wide range of child protection strategies and interventions that the state and territory governments will implement to prevent child abuse and neglect. The focus of these mixed strategies and interventions will be on the provision of primary service and early prevention programs which will be carried out and coordinated by non- government agencies as these have received government funding, including the provision of out of home care services.
All social policy including child protection policies are the result of government legislation, which is the result of a political process, and all policies are the result of an inherent political, ideological process. As critical social workers, it is essential that we are attentive, try to understand and question the changing social and political context in which policies and public interventions are developed and implemented. It is important to be critically aware of the effect of a dominant ideologic

This question has been answered.

Get Answer
WeCreativez WhatsApp Support
Our customer support team is here to answer your questions. Ask us anything!
👋 Hi, Welcome to Compliant Papers.