Think I Found a Wild Bug in VantagePoint

comboGraph.png

Most of today I've been messing with getting the secondary Y axis on the BKSimpleLineGraphApplet in BKit to work with an additional list of the columns of data for the secondary axis. Basically, a guy stopped by and asked if it would be possible to make the dual-Y axis line graph have two lists at the top: one for the primary Y axis and the other for the secondary Y axis. That way, the user could pick what they wanted to plot on the "left" and what they wanted to plot on the "right".

Something like this:

Bogus Double Y Axis Graph

The problem is that I got a lot of it working with just a few additional applet param tags, but there were problems with the selection of the columns of data for the secondary Y axis. I'd say show me the third column, and it'd show me the first. Very odd. I spent quite a while on this until I checked how the BKFixedLineGraphApplet worked -- It had the same problem! This shouldn't be as I wasn't messing with it at all. So there had to be a low-level issue in the BKBaseGraph when dealing with multiple Y axes.

I started running a lot of tests. What it appears to be is an issue with VantagePoint where no matter what 'Variables' you tell it to put on the secondary Y axis, it's only going to put one of the first two. Essentially taking the column number modulo 2.

Ask for columns 2 and 3 (zero-biased indexes) and you'll get columns 0 and 1. Ask for 1 and 2 and you'll get 1 and 0. Very odd. When I tried out the BKSimpleLienGraphApplet with multiple lines on the secondary Y axis, I saw that I picked up on what VantagePoint had thrown down: the first two columns - no matter what. Wild.

So tomorrow I'm going to have to send Gordon an email saying what I've found and asking if the most recent version he's sending me to fix the problem with multiple Y axes and version 4.6.6 will fix this as well. Because I'm sure not going to deliver this to the users - they wanted the pick lists in order to select what's on each axis. As it is now, it's really too broken to deploy.