I have a list like this:
1,kg,cat 1000,g,dog 20,g,apple
And I want to sort it by weight. 1 kg and 1000 g would be the same, so I'd like to have my rows sorted by weight. My data set is larger and has different units, and I want to know how to sort it so that the code can recognize that 3000 g is larger than 1 kg and so on.