Блог пользователя yak_ex

Автор yak_ex, 14 лет назад, По-английски

We can view friend standings and we can view rating history graph for individual. Did you want to view rating history graph with friends? At least, I wanted.

Rating history graph on Codeforces uses flot jQuery plug-in and the plug-in support multiple data sequences. Therefore such functionality can be easily implemented.  If many Codeforces users want, the functionality will be integrated by admin, hopefully.

So, I made user.js script (v1.3 2015/05/05) to show usefulness of the functionality. The latest code is also at github. [Updated: v0.02] Y-axis is adjusted when higher rating is shown, and message box appears when data can't be obtained properly. [Updated: v0.03] While you log-in, your rating graph appears in any profile page initially. [Updated: v1.2] Red dots for the highest ratings are kept and autocomplete for account names is added.

Please note that this is an experimental script and I am just a newbie for user.js script. On my environment, the user.js script works with the following browser:

  • Firefox 3.6.16 with Greasemonkey 0.9.2
  • Opera 11.01
  • Chrome 10.0
Usage is as follows:
  1. Install user.js script. This procedure depends on your environment. Please consult manual for your using software.
  2. Go to a profile page. It is not necessary to be yours. [Updated: v0.03] If you logged-in and go to a profile page other than yours, you can see a graph with your rating graph, like shown as 6,  without the following procedure. To be precise, an original graph is shown at first and updated after a while.
  3. Click legend part, then prompt is shown.

  4. Enter space-separated accounts you want to view with the account of the profile page, and click OK. [Updated: v1.2] If you type more than or equal to 3 characters, autocomplete is triggered like "Find user" feature.

  5. Wait seconds.
  6. Rating graph is updated. Note that the legend moves to bottom-right.

By clicking OK with empty value at prompt, rating graph goes back to original state.
[Updated: v0.03] If you logged-in, your account is entered as default value, except for your profile page. If you want to see an original graph, you need to clear the value and click OK.
Clicking cancel at prompt, rating graph is unchanged.


I hope you enjoy it!
  • Проголосовать: нравится
  • +144
  • Проголосовать: не нравится

14 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится
Very cool, thanks. And can you modify script so that your rating graph appears in profiles?
  • 14 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    >And can you modify script so that your rating graph appears in profiles?

    I'm sorry that I do not understand what you mean, probably. Could you describe what you want in detail?

    • 14 лет назад, # ^ |
        Проголосовать: нравится 0 Проголосовать: не нравится
      I open your profile and see your graph. I want to see both your and my graph.
      • 14 лет назад, # ^ |
          Проголосовать: нравится 0 Проголосовать: не нравится
        This user.js script is applicable to all profile pages at Codeforces. So, after installing this script, you can see both your and my graph by opening my profile and adding your account, or opening your profile and adding my account.
        Maybe I still misunderstood you...
        • 14 лет назад, # ^ |
            Проголосовать: нравится +5 Проголосовать: не нравится
          I want to have my graph in all profiles by default. Every graph I see must contain information about me without adding by clicking on legend.
14 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится
Well done. I like your script - it's very convenient.

Moreover, I study JavaScript on the programming classes at the university these days and now I have an intention to write my own user scripts: your post lets me know about Greasemonkey.
14 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится
I like this amazing script and I'd like if Codeforces Team make it a standard feature of the website :)

Mostly I'd like these two features on CF:

1) To see my graph when I look at other users' graph (as said by freopen)
2) A separate button "compare" that opens another page where you can add up to k different graphs for comparing.

In the (2) point there will be the need of typing down the handle of the users you want to compare, well this could be achieved by re-calling the "Find user" feature present in the homepage.
»
12 лет назад, # |
  Проголосовать: нравится +3 Проголосовать: не нравится

Hi. It seems that now it doesn't show my graph be default. Maybe it's connected with new feature (sharing) on CF graph. (I'm not sure when it became broken)

Does somebody have this problem too?

»
10 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Now Codeforces has a feature that shows with red dot the highest rating ever achieved by user. But script doesn't support this and overloads this feature so the dot is still yellow.

Also, «Colorize standings» now doesn't support newly added languages such as JS and Java 8.

»
10 лет назад, # |
  Проголосовать: нравится +7 Проголосовать: не нравится

Is this extension still working in Chrome?

I tried to install just now, but in step 3, when I click on legend, nothing happens :(

I am using Chrome Version 42.0.2311.90 (64-bit) on MacOS 10.9.5

  • »
    »
    10 лет назад, # ^ |
      Проголосовать: нравится 0 Проголосовать: не нравится

    It has not caught up with HTML changes on the Codeforces site. Now fixed in v1.3. Please try again.

»
6 лет назад, # |
  Проголосовать: нравится +11 Проголосовать: не нравится

So is there any upper bound for the number of accounts one can view?

s

»
5 лет назад, # |
  Проголосовать: нравится +10 Проголосовать: не нравится

Really nice plugin! For people who want to use this, you'll need to change http:// to https:// everywhere in the code to make it work.

»
5 лет назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

How to use it, I installed but dont know how to use ;-;

»
4 года назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Very nice script. Here's how to install it in chrome / chromium: download the script, change all http:// in the script to https://, go to chrome://extensions, drag and drop the script there.

»
4 года назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

am i the only person who is facing problems with that script after the most recent codeforces rating graph update?

  • »
    »
    3 года назад, # ^ |
      Проголосовать: нравится +13 Проголосовать: не нравится

    After rating chart update the javascript code of the website was changed․ I have modified the parser code a bit and now the userscript works. I have also added two variables for settings. You can change their values before installation.

    You can find the modified userscript here.

    • »
      »
      »
      3 года назад, # ^ |
      Rev. 2   Проголосовать: нравится 0 Проголосовать: не нравится

      Configured with Tampermonkey, thx!

      Tutorial