I'm trying to find a percentage to describe how close a generated frequency distribution is to an ideal distribution, but am having a total blank. Basically I need to rate distributions
So say I have the below frequency distributions for a sample size of say 100:
A B
1 0
2 0
3 0
4 100
5 0
6 0
7 0
8 0
The above is my ideal distribution and would receive a rating of 100%
A B
1 1
2 4
3 15
4 50
5 20
6 6
7 3
8 1
The above would also be considered ideal as well with the spike falling on the same frequency and the count is sufficiently larger then the surrounding values so a rating of 100% (or close to)
A B
1 15
2 50
3 20
4 8
5 4
6 2
7 1
8 0
This while having a sufficient sized spike the spiking is happening on the wrong frequency so I want it to be weighted more towards spike happening on the right frequency then the size of the spike. So this might get rated at 50%
A B
1 5
2 30
3 10
4 4
5 6
6 10
7 30
8 5
Then something like this with two large spikes, but one being close to the required frequency might receive a rating of 20%
Basically I'm after a formula to rate a distribution to how close it is to ideal with more weighting towards getting the frequency right (ie the closer the spike is to the ideal frequency the better the score, but the score will also be effected by the the size of the spike and other spikes etc etc.)