I’m working on a small project which involves a large list of words (single words, no sentence) and I would love to have a way to “rate” or “score” each word by some parameters.
Right now I have two parameters I’m looking at:
I’ll use example as example :-)
The length of the word: 7 The count of each letter: 6 (because **e** occurs twice in this word).
I’ve also thought to divide the word into consonants and vowels but haven’t done so yet.
So, from the two parameters, I’ve experimented with two very basic algorithms for “rating” the word:
word-length * (word-length/chars-length) or vice versa word-length * (chars-length/word-length)
For first calculation it will be
7 * (7/6) = 8,16666666666669
And for the second it is:
7 * (6/7) = 6,00000000000002
While this might be useful I’m not sure that I’m actually knowing what I’m doing here :-)
Because if I have a word with a word-length of 15 but the chars-length is only 11, the same two calculations would be 20,4545454545454 and 10,99999999999995
This number is higher than the above and that might be okay because the length of the word is longer, but the uniqueness is less.
I’ve tried to searching Google if there is a more “general” way where a word is rated (not necessarily with these two parameters) but haven’t found anything.
Can anyone help me making a meaningful “rating” og “score” for a word so both is length and it’s “strengthens” is taken into consideration or maybe have some additional parameters to use for this?
I’m sorry if the question does not make sense or if I need to elaborate on something, please let me know.