Open Side Menu Go to the Top
Register
Range Balancer Software (Java) Range Balancer Software (Java)

04-05-2009 , 10:20 AM
made this program this morning while acquainting myself with java swing. not sure if there is a program already like it but w/e.
Basically if you're in a spot that you want to call or bet say 33% of the time or half etc... you type it in and see if it's that time or not. This way you're not guessing how often you're doing something.
You can also test the algorithm in case you're wondering if it's random enough.

Green background means to do whatever you wanted to do that % of time
Red background means don't do it.
You'll have to figure out how to use it and what spots, I don't have the answers for that.

you can download it here and just run the jar if you have java installed
http://www.mediafire.com/?we2gyyh30gm

if you don't have java
http://www.java.com/en/download/index.jsp

screenshot (yeah pretty basic )



comments or suggestions welcome
Code:
package Randomizer;
import java.awt.Color;
import java.awt.Container;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;
import javax.swing.JTextField;
import javax.swing.JButton;
import javax.swing.JFrame;
import javax.swing.JPanel;
import java.util.*;
import java.util.Random;
import javax.swing.JTextArea;
public class Randomizer extends JPanel implements ActionListener {
    private JButton goButton = new JButton("Balance");
    private JButton resetButton = new JButton("Reset");
    private JButton testButton = new JButton("Test");
    private JTextField balance = new JTextField(2);
    private JTextArea ta = new JTextArea(3, 10);



    public Randomizer() {
        add(resetButton);
        add(goButton);
        add(balance);
        add(testButton);
        add(ta);
        balance.setText("0");
        goButton.addActionListener(this);
        resetButton.addActionListener(this);
        testButton.addActionListener(this);
  }
    public void actionPerformed(ActionEvent evt) {
        int entry = 0;
        Object source = evt.getSource();
        Color color = getBackground();
        if (source == resetButton){
            color = Color.white;
            balance.setText("0");
            ta.setText("");
        }
        else if (source == goButton){
            entry = getter();
            int random = rando();
            if (random < entry){
                color = Color.green;
                ta.setText("Go Go Go!");
            }else if (random >= entry){
                color = Color.red;
                ta.setText("No No No!");

            }
        }
        else if (source==testButton)
            tester();


        setBackground(color);
        repaint();
    }
    public int getter(){
        int e = 0;
        try {
            e = Integer.parseInt(balance.getText());
            }catch  ( NullPointerException npe )   {    e = 0;}
             catch  ( NumberFormatException nfe )   {   e = 0; }
        return e;
    }

    public void tester(){
        ta.setText("");
        int pos = 0; int neg = 0;
        int testEntry = getter();
        for (int i = 0;i<100000;i++){
            int testRand = rando();
            if (testRand < testEntry)
                pos++;
            else if (testRand >= testEntry)
                neg++;
        }
       ta.append("Testing 100000 simulations\n");
       ta.append("There were " + pos + " positives\n");
       ta.append("There were " + neg + " negatives\n");

    }



    public static int rando(){
        int hi = 99; int lo = 0;
        Random rn = new Random();
        int n = hi - lo + 1;
        int i = rn.nextInt() % n;
        if (i < 0)
            i = -i;
        return lo + i;
    }

    public static void main(String[] args) {
        JFrame frame = new JFrame("Range Balancer by jwc529");
        frame.setSize(275, 125);
        frame.addWindowListener(new WindowAdapter() {

    public void windowClosing(WindowEvent e) {
        System.exit(0);
    }
    });
    Container contentPane = frame.getContentPane();
    contentPane.add(new Randomizer());
    frame.show();
  }
}
Range Balancer Software (Java) Quote
04-05-2009 , 10:28 AM
Ehh, I guess it's the wrong forum. And ehhm, I'm not sure if it's really useful either, but I like your enthusiasm! Might look over the code tonight if I'm bored. :P
Range Balancer Software (Java) Quote
04-05-2009 , 10:41 AM
Quote:
Originally Posted by TimberBee
Ehh, I guess it's the wrong forum. And ehhm, I'm not sure if it's really useful either, but I like your enthusiasm! Might look over the code tonight if I'm bored. :P
well it's poker related so I figured I'd just put it on 2+2

It's probably not that useful overall where in some spots you'll just do something all the time. I got the idea when I read how harrington looks at his watch to decide what to do % of time, and wondered if people onlne are really looking at their watches if they play like that, lol.

Last edited by jwc529; 04-05-2009 at 11:02 AM.
Range Balancer Software (Java) Quote
04-05-2009 , 11:10 AM
i was actually just thinking of doing something like this to make me balance out my river calls. might take a look, after I make sure it isn't a keylogger.
Range Balancer Software (Java) Quote
04-05-2009 , 01:29 PM
vn, thought of this as a usefull tool, too
thx!
Range Balancer Software (Java) Quote
04-05-2009 , 02:18 PM
Looks like a solid program!
Range Balancer Software (Java) Quote
04-05-2009 , 04:11 PM
choose some numbers and look at your watch
Range Balancer Software (Java) Quote
04-05-2009 , 05:03 PM
Quote:
Originally Posted by cmyr
i was actually just thinking of doing something like this to make me balance out my river calls. might take a look, after I make sure it isn't a keylogger.
oops, forgot the stealMonies() function

That's kind of why I included the code, so people could compile it themselves if they like and see there is no funny business.
Range Balancer Software (Java) Quote
04-05-2009 , 09:26 PM
i have one of these:



teddy monroe sold it to me.

But your program looks cool. I thought you'd input hands you'd have after making a specific play, and it would tell you other hands you should make that play w/ to balance your range.
Range Balancer Software (Java) Quote
04-06-2009 , 08:51 AM
Quote:
Originally Posted by donkeykong2
choose some numbers and look at your watch
Ya, I read Andy Beal would do something like this when playing those live HU matches. If you want to balance something 50/50 or 25/75 % of the time just look at your watch (not digital) and wherever the second hand is, use that as an indicator. So each 15 seconds represents 25% and each 30 seconds is 50% etc.
Range Balancer Software (Java) Quote
04-06-2009 , 02:46 PM
Quote:
Originally Posted by sc000t
Ya, I read Andy Beal would do something like this when playing those live HU matches. If you want to balance something 50/50 or 25/75 % of the time just look at your watch (not digital) and wherever the second hand is, use that as an indicator. So each 15 seconds represents 25% and each 30 seconds is 50% etc.


also works when watch is digital, ducy?
Range Balancer Software (Java) Quote
04-06-2009 , 06:04 PM
Or just press the random number generator button on a calculator
Range Balancer Software (Java) Quote
04-07-2009 , 06:08 AM
just always do the gogogogogogo option. failproof
Range Balancer Software (Java) Quote
08-25-2009 , 11:01 PM
can someone reupload this pls?

or explain how i copy and paste the text (i tried to notepad saving as .jar but didnt work)

thanks
Range Balancer Software (Java) Quote
08-25-2009 , 11:15 PM
this looks cool
Range Balancer Software (Java) Quote
08-26-2009 , 04:16 PM
Quote:
Originally Posted by jipster
can someone reupload this pls?

or explain how i copy and paste the text (i tried to notepad saving as .jar but didnt work)

thanks
it doesn't work like that, you need a java compiler on your system. I mostly just included the code in case a programmer on here wanted to tweak it or something

I reupped it to another site, but people can just pm me if that site stops hosting it too.
http://www.megaupload.com/?d=095ME6JO
Range Balancer Software (Java) Quote
08-26-2009 , 05:04 PM
thanks jwc, cute program seems to work fine; not sure if i'll ever use it whilst rake monkeying but if im 4 tabling it would probably come in useful

thanks
Range Balancer Software (Java) Quote
03-16-2015 , 07:32 PM
are these type of programs, that help you mix your ranges both preflop/postflop, OK to use on PokerStars?
Range Balancer Software (Java) Quote
03-17-2015 , 11:42 PM
How the hell did you find a 6 year old thread
Range Balancer Software (Java) Quote

      
m