Riot has said the ranks are a percentile system.
https://support.riotgames.com/hc/en-us/articles/204211284-Champion-Mastery-Guide#h1q4
Riot is basically saying, they have a database of lots of statistics and if you fall into the bell curve at the right place, you get the grade you want. I don't know the exact stats but if the statistics are percentile based the below should be an approximation of the frequency of the grades.
http://imgur.com/a/ALPLw
Your grade is based on your champion and role and overall stats like KDA, CS, damage done, damage tanked, wards, etc... depending on what your role was.
So going by the example in the riot page:
You can pick Annie and play her in two lanes but your grade basis will change
If you play Annie Mid, you're expecting to do more damage, get more CS, and lay fewer wards.
If you play Annie Support, you're expecting to do less damage, get less CS, and lay more wards.
Based on their page, they say they collect the metrics.
You play Annie mid in a game.
You have to base your personal statistics to the scale of Annie mids, not Annies in general but Annie mid specifically.
You have to make sure that on average you're doing more damage than other Annie mids, getting more CS than Annie mids, dying less then Annie mids, putting more wards down with Annie mids, etc... Then you'll get higher and higher grades.
So based on the riot statement, my best guess is that if you're performing at the cream of the crop level, you'll be getting A's and S's BUT if everyone else starts improving their game play, then you also have to improve your stats to stay at the A and S level.