Data visualization Q: how to easily make a histogram

(I really hope histogram is the right term. )

I am the Keeper of the Spreadsheet for the Thursday night SDMB poker game. We inevitably have some screwy showdowns. So, I am curious about what a histogram of winning hands might look like (best pair, two pair, trips, etc.). I can get text files of hand histories* to scan through for winning hands, but I’m at loss how to take that information and easily plug it into an OpenOffice spreadsheet to get a graph. (In fact, I haven’t been using OO long enough to know how to make any graph. )

Bearing in mind that the less effort expended on this, the better, any ideas?

*I can put a sample up in Google Docs if anyone wants to play with it.

I don’t know about OpenOffice, but someone here linked to a free program called GeoGebra that allows you to do algebra, geometry, graphing, and charting all in one program in a fairly intuitive way.

In MS Excel, you can do it by installing the Data Analysis ToolPak, which has a histogram tool built in. Don’t know if Oo.o has an equivalent. You might be able to jury rig some formulae in either program to make it.

However, I might be confused at what you are trying to do. Is each column on the graph a separate hand? If you can easily manually convert to a frequency table, it should be easy to do using a bar graph, or column graph as it is called in these programs for vertical. It doesn’t sound like you need to worry about binning.

One axis would be “high card”, “one pair”, “two pair”, … , “straight flush”. The other axis would number of times or percent of times that particular hand won a game.

What I can’t wrap my head around is how to get the raw data onto a spreadsheet that would generate the numbers.

Just a few weeks ago I had to help my wife create something similar in OO.o. Since she was doing the data analysis, I only remember sketchy broadstrokes, though. From the menu, choose “Insert -> Function…” (looking at my v3.0 install, you can use ctrl+F2). On the category drop-down list, choose Array, then Frequency. There was something she also had to do to form “bins” (it was numerical data)…I think it gave her an option to do so. IIRC, you’ll be able to select a range of cells (and perhaps other options).

Graphing shouldn’t be an issue, but again, my wife did that once I figured out how to get a frequency.

I figured out what I want to try. I’ll slide over a few columns to leave room for calculations, then enter all winning hands from a game using a two-letter code: HC, PR, 2P, TR, ST, FL, FH, 4K, SF in a single column per game. In my calculation area, I’ll use COUNTIF(…) to sum the results, then probably convert to percentages.

That leaves the graphing…