Protests and online activism in recent months have brought a resurgence of ethnic Oromo nationalism in Ethiopia. 01 Aug 2014 12:37 GMT | Human Rights, Africa, Ethiopia. Oromo students protested against a government plan to expand Addis Ababa [Jawar Mohammed/Al Jazeera]
You just have to substitute values of slope and vertical distance in formula and get value of horizontal distance. Similarly, any one of them can be found if other two are given. For instance, if you have a slope given in Percentage as 10 % and a vertical distance of 50 feet, then equation will look like:
Your first step would be to decide on a distance/dissimilarity function between your observations. One option is to transform your categorical variables into dummy binary variables and then calculate the Jaccard distance between each row pair. Here is a simple tutorial for these steps. Once you have a distance defined you can proceed with the KNN algorithm as usual.