Re: [Scidvspc-users] New tree bargraph
Chess Database and Toolkit program
Brought to you by:
stevenaaus
|
From: Steven <ste...@ya...> - 2012-01-26 20:14:10
|
Here's a windows snapshot with the new tree graph, and clickable tablebase moves in the gameinfo window. http://sourceforge.net/projects/scidvspc/files/windows-beta/scidvspc_20120126.zip/download Benigno wrote: > Why not leave the color settings for the user? Options -> Colors Hmmmm.... They initially didn't look great on a white background, but i've addressed this. > I think: > scan [string range $line 33 37] "%f%%" success > scan [string range $line 60 end] "%f%%" draw > set notdrawn [expr {100-$draw}]> set wonx [expr {($sucess-$notdrawn)*3.0/500+1}];> set lossx [expr{61-(((100-$sucess)-$notdrawn)*3.0/500)}] Do you mean my claculations were wrong :( Yes - this has been corrected already in svn and they should be ok now set wonx [expr {($success - $draw/2)*0.6 + 1}] ; # win = success - drawn/2 set lossx [expr {($success + $draw/2)*0.6 + 1}] ; # loss = 100 - win - drawn Steve From: Benigno Hernández <sn...@ya...> Subject: Re: [Scidvspc-users] New tree bargraph To: "Steven" <ste...@ya...> Received: Friday, 27 January, 2012, 3:15 AM Hi, Why not leave the color settings for the user? Options -> Colors Items = N (number of games) Points = p; d=draws number; w= wins number. % Wins = w / N * 100 = (p - t) / N * 100 % Draws = d / N * 100 % Losses = (N-p) / N * 100I think: scan [string range $line 33 37] "%f%%" success scan [string range $line 60 end] "%f%%" draw set notdrawn [expr {100-$draw}] set wonx [expr {($sucess-$notdrawn)*3.0/500+1}]; set lossx [expr{61-(((100-$sucess)-$notdrawn)*3.0/500)}] Benigno ----- Mensaje original ----- De: Steven <ste...@ya...> Para: Gregor Cramer <gc...@gm...>; sci...@li... CC: Enviado: Martes 24 de enero de 2012 6:53 Asunto: [Scidvspc-users] New tree bargraph Hi, I'm doing some work with the tree widget and some feedback would be good. Attached is a picture of it working so far (which i'll tidy up and commit to svn in a sec). There's two colour sets. I'm not sure which to use , but i'm definitely thinking to use white/black rather than green/red colours. White/Black is less attractive but more meaningful. I think i can remove the tree ECO field and the huge "Bar Graph" window altogether. Does anyone use these things ? I've also removed the red and green stat highlighting, which uses some arcane function of AvElo and Freq, and is the subject of bug reports in SCID and Scidvspc. I should probably *not* draw a little graph at all if the frequency is less than a certain amount. What should this be ? 100 games or 5 to 10% is what i'm thinking. Percentages are normally better i guess. A couple of technical questions for Gregor - 1. Are my percentages correct ? "sc_tree search" gives success and draw percentages, and to convert them into games won/drawn/loss i subtract the drawn % from 100, then divy up this according to success% and (100-success%). Of course i could do this calculation in sc_tree search, but there's not much diff, optable also uses "sc_tree search", and keeping compatability with SCID is good. 2. I've embedded canvas windows into the text widget, but i can't see how to pass the text mouse bindings to the canvas. Any idea about this.. It's not too important though. thanks, Steve PS I've been doing some minor tablebase work. Tablebase winning and drawn moves in the gameinfo area are now clickable, and the TB window has been tidied up a bit. And the analysis engine windows no longer have wrapped text. ---------------tree.tcl-------------------------------------- ### Create the small green/white/red bar graph scan [string range $line 33 37] "%f%%" success scan [string range $line 60 end] "%f%%" draw set notdrawn [expr {100-$draw}] set wonx [expr {$success * $notdrawn * 3.0/500 + 1}] ; # 3/500 is 1/100 * 60(pixels) / 100 set lossx [expr {61 - ((100 - $success) * $notdrawn * 3.0/500)}] $w.f.tl window create end-32c -create [list createCanvas %W.g$i $wonx $lossx] # end-32c is between the Freq and Score proc createCanvas {w wonx lossx} { canvas $w -width 60 -height 12 -bg grey75 # 0 to $wonx is coloured white # $lossx to 61 is coloured black # (There's some +/- 1 to acount for widget borders) $w create rectangle 0 0 $wonx 13 -fill white -width 0 $w create rectangle $lossx 0 61 13 -fill grey10 -width 0 return $w } ------------------------------------------------------------------------------ Keep Your Developer Skills Current with LearnDevNow! The most comprehensive online learning library for Microsoft developers is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3, Metro Style Apps, more. Free future releases when you subscribe now! http://p.sf.net/sfu/learndevnow-d2d _______________________________________________ Scidvspc-users mailing list Sci...@li... https://lists.sourceforge.net/lists/listinfo/scidvspc-users |