player a vs. player b TWIXT PP

20 replies. Last post: 2015-09-07

Reply to this topic Return to forum

player a vs. player b
  • CSM at 2011-04-01

    Hi. Could one of you smart, computer wizard types come up with a program that could do a head-to-head comparison between any two players? Otherwise, I have to go back through all my games to see how I have done and how I compare with another player. As much as I (we) like TwixT, I would think this could be done and I believe most players would use and appreciate it. Thank you.

  • Alan Hensel at 2011-04-02

    I’m not volunteering, but what stat, specifically, do you want? I am always in favor of more stats on LG, and have at times advocated tracking win-loss records between players – for example, it would be nice to know, when starting a game with someone, how many wins and losses against that person you already have. But it sounds like you want something more than that?

  • CSM at 2011-04-02

    Yes, that’s the main thing I’m looking for but I don’t really have anything else in mind right now and would be open to any other stats someone could come up with. However, I don’t even have a clue as to how difficult this idea is to create a program and can only suggest someone might try try it. Btw, I was thinking of you, Alan. :)

  • Dvd Avins at 2011-04-02

    I’d like to see a page with links to all the games I’ve had against a player.

  • MarleysGhost at 2011-04-02

    To compare player A, whose player id is idA, with player B, whose name is name B, with something like

    wget “”|grep -A 4 “>nameB<”|grep ‘>win<’|wc

    wget “”|grep -A 4 “>nameB<”|grep ‘>lost<’|wc

    to count the number of times player A has won and lost against player B.

    I realize this may seem opaque if you’re not familiar with shell scripts.

  • CSM at 2011-04-02

    MarleysGhost, whats your point? (in english, please)

  • Alan Hensel at 2011-04-03

    Nice Linux hackery, MarleysGhost. But not everyone’s on Linux.

    OK, here’s my hackery. It requires you to have Firefox or Google Chrome as your browser, and don’t have JavaScript turned off. There are almost certainly ways to get this to work in other browsers, but I have not tested them.

    If you have Firefox, first install GreaseMonkey (Tools --> Add-ons, search for “greasemonkey”; version 0.9.1 was released in January). If you have Google Chrome as your browser, you can skip this step – GreaseMonkey is built in.

    Then, download the lg_record script I just hacked up:
    You can try just clicking on the link. If that doesn’t work, go back, right-click the link, “Save As...”, then drag and drop the file into the browser window.

    Then, whenever you go to the player games list, a win-loss record table should appear to the right. Have fun.

  • iwin at 2011-04-05

    Or....create an excel spreadsheet....

  • FatPhil at 2011-04-05

    You don’t need linux to run a simple shell script, just grab wget and grep.
    You don’t need wc, as that’s what the ‘-c’ switch in grep is for. Slap wristies – MarleysGhost.

  • Alan Hensel at 2011-04-05

    iwin, do you have an excel spreadsheet that does win-loss calculations and/or filters by opponent automatically, or does other interesting calculations? Some people might prefer that over a GreaseMonkey script or a shell script. Me, I’m lazy, I don’t feel like cutting and pasting from a browser table to excel, and I don’t mind having a little GreaseMonkey script installed, but to each his own.

  • MarleysGhost at 2011-04-05

    -c? Well, live and learn.

    I used Macintosh, which has grep and the superfluous wc, but not wget, for which I substituted a program I wrote. You could do Save As.. from a browser, but then it’s starting to be a hassle.

  • iwin at 2011-04-05

    Excel has tons of math “functions” to choose from. Percentages, averages, medians..etc. Just cut/paste, sort by the column of your choice and plug in your function of choice. (It took longer to type this message then do the steps as described above but then I’ve been using excel for a long time.)

  • zwack at 2011-04-05

    That’s a handy sc-ript. Thanks, Alan.

  • CSM at 2011-04-06

    Hey, it even worked for me, THANK YOU, Alan. I’d not even heard of Google Chrome, but I downloaded it and now I’m not going back to Internet Explorer. Any time you want to recommend something for us computer dummies, please do. :-)

  • maraca at 2011-04-06

    I’m always astonished how intelligent all the people of lg together are.

    If you wanna test Marley’s script on windows you can use:
    - Cygwin
    - unixutils

  • Alan Hensel at 2011-04-09

    I realized that Dvd Avins' request would be easy to implement, and useful to me, so I did it.

    Now, after installing the GreaseMonkey script, you can click on the “<<” next to any name on the right, and see just the games with that opponent on the left. Click “all” to restore the full list.

    LG Record, version 2.0.

    You might have to uninstall version 1.0. I haven’t tested that.

  • Dvd Avins at 2011-04-09

    Thank you. Ideally (at least for me) a page will all the different games (Twixt, chess, etc.) I had against a player would be on the same page, but that data is not available on one page for you to process, it would have to be done by Richard or with considerably more work, I imagine. This script as it stands now is still quite useful.

  • elroy at 2011-04-16

    Nice! Thank you Alan! I have been away from LG for awhile (way too much work to do)and just saw this forum while checking how far from championship 28 we are (three games that are all already over and just need resignations but who knows how long that will take?) This will be of great use when I start playing again when 28 starts. Thanks again.

  • edbonnet at 2015-09-06

    Is it possible to adapt the script lg_record2.user.js to the current version of the website?

  • Alan Hensel at 2015-09-07

    Maybe. I think the bigger problem is getting around browser security. It’s pretty tight these days. It would be better if LG were to natively deliver more detailed stats.

Return to forum

Reply to this topic

Include game board: [game;id:123456] or [game;id:123456;move:20] or [game;id:123456;move:20;title:some text]